[Zope3-checkins] CVS: Zope3/src/zope/app/index - processors.py:1.5
Steve Alexander
steve@cat-box.net
Mon, 30 Dec 2002 13:43:37 -0500
Update of /cvs-repository/Zope3/src/zope/app/index
In directory cvs.zope.org:/tmp/cvs-serv29407/src/zope/app/index
Modified Files:
processors.py
Log Message:
Implemented InterfacesField to select several interfaces.
Refined the query interfaces.
=== Zope3/src/zope/app/index/processors.py 1.4 => 1.5 ===
--- Zope3/src/zope/app/index/processors.py:1.4 Mon Dec 30 09:03:06 2002
+++ Zope3/src/zope/app/index/processors.py Mon Dec 30 13:43:06 2002
@@ -26,8 +26,6 @@
from zope.component import getAdapter, getService
from zope.proxy.context import ContextMethod
-
-
class ObjectRetrievingProcessor:
"""Converts a RankedHubIdList into an iteratable
list of ranked objects by retrieving the objects
@@ -36,8 +34,8 @@
__implements__ = IQueryProcessor
- input_interface = IRankedHubIdList, IBatchedResult
- output_interface = IRankedObjectIterator
+ inputInterfaces = (IRankedHubIdList, IBatchedResult)
+ outputInterfaces = (IRankedObjectIterator,)
def __call__(wrapped_self, query):
list = getAdapter(query, IRankedHubIdList)
@@ -46,8 +44,10 @@
objectHub = getService(wrapped_self, "HubIds")
# XXX do we need wrapping for the objects returned by the hub?
- iterator = RankedObjectIterator(list, objectHub.getObject, batch.startPosition,
- batch.batchSize, batch.totalSize)
+ iterator = RankedObjectIterator(
+ list,objectHub.getObject, batch.startPosition,
+ batch.batchSize, batch.totalSize
+ )
return iterator
__call__ = ContextMethod(__call__)
@@ -57,7 +57,8 @@
__implements__ = IRankedObjectIterator, IBatchedResult
- def __init__(self, recordlist, objectfetcher, startposition, batchsize, totalsize):
+ def __init__(self, recordlist, objectfetcher, startposition,
+ batchsize, totalsize):
self._records = recordlist
self.startPosition = startposition
self.batchSize = batchsize