Back to index

plone3  3.1.7
Public Member Functions | Public Attributes | Static Public Attributes
plone.app.controlpanel.ram.RAMCacheControlPanel Class Reference
Inheritance diagram for plone.app.controlpanel.ram.RAMCacheControlPanel:
Inheritance graph
[legend]
Collaboration diagram for plone.app.controlpanel.ram.RAMCacheControlPanel:
Collaboration graph
[legend]

List of all members.

Public Member Functions

def getStatistics
def restricted_actions
def handle_clearall_action
def handle_edit_action
def handle_cancel_action
def setUpWidgets
def is_fieldsets

Public Attributes

 status
 adapters
 widgets

Static Public Attributes

 base_template = _template
tuple template = ZopeTwoPageTemplateFile('ram.pt')
tuple form_fields = form.FormFields(IRAMCacheSchema)
tuple label = _("RAM Cache Settings")
 description = None
tuple form_name = _("RAM Cache Settings")
 validator = null_validator,
string name = u'cancel'

Detailed Description

Definition at line 71 of file ram.py.


Member Function Documentation

Definition at line 82 of file ram.py.

00082 
00083     def getStatistics(self):
00084         return getUtility(IRAMCache).getStatistics()

Reimplemented from plone.app.controlpanel.form.ControlPanelForm.

Definition at line 109 of file ram.py.

00109 
00110     def handle_cancel_action(self, action, data):
00111         IStatusMessage(self.request).addStatusMessage(_("Changes canceled."),
00112                                                       type="info")
00113         url = getMultiAdapter((self.context, self.request),
00114                               name='absolute_url')()
00115         self.request.response.redirect(url + '/plone_control_panel')
00116         return ''

Here is the call graph for this function:

Definition at line 90 of file ram.py.

00090 
00091     def handle_clearall_action(self, action, data):
00092         CheckAuthenticator(self.request)
00093         context = aq_inner(self.context)
00094         getUtility(IRAMCache).invalidateAll()
00095         self.status = _(u'Cleared the cache.')

Here is the call graph for this function:

Reimplemented from plone.app.controlpanel.form.ControlPanelForm.

Definition at line 97 of file ram.py.

00097 
00098     def handle_edit_action(self, action, data):
00099         CheckAuthenticator(self.request)
00100         if form.applyChanges(self.context, self.form_fields, data,
00101                              self.adapters):
00102             self.status = _("Changes saved.")
00103             self._on_save(data)
00104         else:
00105             self.status = _("No changes made.")

Here is the call graph for this function:

Definition at line 36 of file form.py.

00036 
00037     def is_fieldsets(self):
00038         # We need to be able to test for non-fieldsets in templates.
00039         return IFormFieldsets.providedBy(self.form_fields)
00040 

Here is the caller graph for this function:

Definition at line 85 of file ram.py.

00085 
00086     def restricted_actions(self):
00087         return [a for a in self.actions.actions
00088                   if a.__name__ in ('form.actions.save', 'form.actions.cancel')]

def plone.fieldsets.form.FieldsetsEditForm.setUpWidgets (   self,
  ignore_request = False 
) [inherited]

Definition at line 13 of file form.py.

00013 
00014     def setUpWidgets(self, ignore_request=False):
00015         # First part is copied from zope.formlib.form.EditForm licensed under
00016         # the ZPL 2.1
00017         self.adapters = {}
00018         # In order to support fieldsets, we need to setup the widgets on all
00019         # the fieldsets as well.
00020         if self.is_fieldsets():
00021             self.widgets = None
00022             for fieldset in self.form_fields.fieldsets:
00023                 fieldset.widgets = form.setUpEditWidgets(
00024                     fieldset, self.prefix, self.context, self.request,
00025                     adapters=self.adapters, ignore_request=ignore_request
00026                     )
00027                 if self.widgets is None:
00028                     self.widgets = fieldset.widgets
00029                 else:
00030                     self.widgets += fieldset.widgets
00031         else:
00032             self.widgets = form.setUpEditWidgets(
00033                 self.form_fields, self.prefix, self.context, self.request,
00034                 adapters=self.adapters, ignore_request=ignore_request
00035                 )


Member Data Documentation

Definition at line 16 of file form.py.

Definition at line 73 of file ram.py.

Definition at line 79 of file ram.py.

Definition at line 76 of file ram.py.

tuple plone.app.controlpanel.ram.RAMCacheControlPanel.form_name = _("RAM Cache Settings") [static]

Definition at line 80 of file ram.py.

tuple plone.app.controlpanel.ram.RAMCacheControlPanel.label = _("RAM Cache Settings") [static]

Definition at line 78 of file ram.py.

Reimplemented from plone.app.controlpanel.form.ControlPanelForm.

Definition at line 108 of file ram.py.

Reimplemented from plone.app.controlpanel.form.ControlPanelForm.

Definition at line 94 of file ram.py.

tuple plone.app.controlpanel.ram.RAMCacheControlPanel.template = ZopeTwoPageTemplateFile('ram.pt') [static]

Definition at line 74 of file ram.py.

Reimplemented from plone.app.controlpanel.form.ControlPanelForm.

Definition at line 107 of file ram.py.

Definition at line 20 of file form.py.


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