Back to index

plone3  3.1.7
Public Member Functions | Public Attributes | Static Public Attributes | Private Attributes
CMFFormController.FormAction.FormActionContainer Class Reference
Inheritance diagram for CMFFormController.FormAction.FormActionContainer:
Inheritance graph
[legend]
Collaboration diagram for CMFFormController.FormAction.FormActionContainer:
Collaboration graph
[legend]

List of all members.

Public Member Functions

def __init__
def __copy__
def set
def get
def delete
def match
def getFiltered

Public Attributes

 actions

Static Public Attributes

tuple security = ClassSecurityInfo()

Private Attributes

 _p_changed

Detailed Description

Definition at line 130 of file FormAction.py.


Constructor & Destructor Documentation

Definition at line 135 of file FormAction.py.

00135 
00136     def __init__(self):
00137         self.actions = {}


Member Function Documentation

Definition at line 138 of file FormAction.py.

00138 
00139     def __copy__(self):
00140         newobj = FormActionContainer()
00141         for a in self.actions.values():
00142             newobj.set(a.__copy__())
00143         return newobj

Definition at line 151 of file FormAction.py.

00151 
00152     def delete(self, key):
00153         del self.actions[key]
00154         self._p_changed = 1

Definition at line 148 of file FormAction.py.

00148 
00149     def get(self, key):
00150         return self.actions[key]

Here is the caller graph for this function:

def CMFFormController.FormAction.FormActionContainer.getFiltered (   self,
  object_id = _marker,
  status = _marker,
  context_type = _marker,
  button = _marker,
  action_type = _marker,
  action_arg = _marker 
)

Definition at line 187 of file FormAction.py.

00187 
00188                     button=_marker, action_type=_marker, action_arg=_marker):
00189         filtered = []
00190         keys = self.actions.keys()
00191         keys.sort()
00192         for key in keys:
00193             action = self.actions[key]
00194             if object_id != _marker and not action.getObjectId() == object_id:
00195                 continue
00196             if status and not action.getStatus() == status:
00197                 continue
00198             if context_type != _marker and not action.getContextType() == context_type:
00199                 continue
00200             if button != _marker and not action.getButton() == button:
00201                 continue
00202             if action_type != _marker and not action.getActionType() == action_type:
00203                 continue
00204             if action_arg != _marker and not action.getActionArg() == action_arg:
00205                 continue
00206             filtered.append(action)
00207         return filtered
00208 
00209 InitializeClass(FormActionContainer)

Here is the caller graph for this function:

def CMFFormController.FormAction.FormActionContainer.match (   self,
  object_id,
  status,
  context_type,
  button 
)

Definition at line 155 of file FormAction.py.

00155 
00156     def match(self, object_id, status, context_type, button):
00157         controller = getToolByName(self, 'portal_form_controller')
00158         action = None
00159         try:
00160             action = self.actions.get(FormActionKey(object_id, status, \
00161                                         context_type, button, controller), None)
00162             if action:
00163                 return action
00164         except ValueError:
00165             pass
00166         try:
00167             action = self.actions.get(FormActionKey(object_id, status, \
00168                                             ANY_CONTEXT, button, controller), None)
00169             if action:
00170                 return action
00171         except ValueError:
00172             pass
00173         try:
00174             action = self.actions.get(FormActionKey(object_id, status, \
00175                                             context_type, ANY_BUTTON, controller), None)
00176             if action:
00177                 return action
00178         except ValueError:
00179             pass
00180         try:
00181             return self.actions.get(FormActionKey(object_id, status, \
00182                                             ANY_CONTEXT, ANY_BUTTON, controller), None)
00183         except ValueError:
00184             pass
00185         return None

Here is the call graph for this function:

Definition at line 144 of file FormAction.py.

00144 
00145     def set(self, action):
00146         self.actions[aq_base(action.getKey())] = aq_base(action)
00147         self._p_changed = 1

Here is the caller graph for this function:


Member Data Documentation

Definition at line 146 of file FormAction.py.

Definition at line 136 of file FormAction.py.

tuple CMFFormController.FormAction.FormActionContainer.security = ClassSecurityInfo() [static]

Definition at line 132 of file FormAction.py.


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