Back to index

plone3  3.1.7
Public Member Functions | Private Attributes
CMFPlone.CatalogTool.ExtensibleIndexableObjectWrapper Class Reference
Inheritance diagram for CMFPlone.CatalogTool.ExtensibleIndexableObjectWrapper:
Inheritance graph
Collaboration diagram for CMFPlone.CatalogTool.ExtensibleIndexableObjectWrapper:
Collaboration graph

List of all members.

Public Member Functions

def __init__
def update
def beforeGetattrHook
def __getattr__
def allowedRolesAndUsers

Private Attributes


Detailed Description

Extensible wrapper for object indexing.

vars - additional vars as a dict, used for workflow vars like review_state
obj - the indexable object
portal - the portal root object
registry - a registry
**kwargs - additional keyword arguments

Definition at line 71 of file

Constructor & Destructor Documentation

def CMFPlone.CatalogTool.ExtensibleIndexableObjectWrapper.__init__ (   self,
  registry = _eioRegistry 

Definition at line 84 of file

00085     def __init__(self, obj, portal, registry = _eioRegistry):
00086         # Because we want to look this up as an adapter, we defer 
00087         # initialisation until the update() method is called
00088         super(ExtensibleIndexableObjectWrapper, self).__init__({}, obj)
00089         self._portal = portal
00090         self._registry = registry
00091         self._kwargs = {}

Member Function Documentation

Definition at line 101 of file

00102     def __getattr__(self, name):
00103         vars = self._IndexableObjectWrapper__vars
00104         obj = self._IndexableObjectWrapper__ob
00105         kwargs = self._kwargs
00106         registry = self._registry
00108         vars, obj, kwargs = self.beforeGetattrHook(vars, obj, kwargs)
00110         if registry.has_key(name):
00111             return registry[name](obj, portal=self._portal, vars=vars, **kwargs)
00112         return super(ExtensibleIndexableObjectWrapper, self).__getattr__(name)

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 113 of file

00114     def allowedRolesAndUsers(self):
00115         # Disable CMFCore version of this method; use registry hook instead
00116         return self.__getattr__('allowedRolesAndUsers')

Here is the call graph for this function:

def CMFPlone.CatalogTool.ExtensibleIndexableObjectWrapper.beforeGetattrHook (   self,

Definition at line 98 of file

00099     def beforeGetattrHook(self, vars, obj, kwargs):
00100         return vars, obj, kwargs

Here is the caller graph for this function:

def CMFPlone.CatalogTool.ExtensibleIndexableObjectWrapper.update (   self,

Definition at line 92 of file

00093     def update(self, vars, **kwargs):
00094         self._IndexableObjectWrapper__vars = vars
00095         self._kwargs = kwargs
00096         if 'registry' in kwargs:
00097             self._registry = kwargs['registry']

Here is the caller graph for this function:

Member Data Documentation

Definition at line 93 of file

Definition at line 90 of file

Definition at line 88 of file

Definition at line 89 of file

The documentation for this class was generated from the following file: