Back to index

plone3  3.1.7
Public Member Functions | Public Attributes | Static Public Attributes | Static Private Attributes
Marshall.handlers.base.Marshaller Class Reference

List of all members.

Public Member Functions

def __init__
def initializeInstance
def cleanupInstance
def demarshall
def marshall
def initializeField
def cleanupField

Public Attributes

 demarshall_hook
 marshall_hook

Static Public Attributes

tuple security = ClassSecurityInfo()

Static Private Attributes

 __implements__ = IMarshall,ILayer

Detailed Description

Definition at line 37 of file base.py.


Constructor & Destructor Documentation

def Marshall.handlers.base.Marshaller.__init__ (   self,
  demarshall_hook = None,
  marshall_hook = None 
)

Definition at line 44 of file base.py.

00044 
00045     def __init__(self, demarshall_hook=None, marshall_hook=None):
00046         self.demarshall_hook = demarshall_hook
00047         self.marshall_hook = marshall_hook


Member Function Documentation

def Marshall.handlers.base.Marshaller.cleanupField (   self,
  instance,
  field 
)

Definition at line 73 of file base.py.

00073 
00074     def cleanupField(self, instance, field):
00075         pass
00076 
00077 InitializeClass(Marshaller) 
def Marshall.handlers.base.Marshaller.cleanupInstance (   self,
  instance,
  item = None,
  container = None 
)

Definition at line 58 of file base.py.

00058 
00059     def cleanupInstance(self, instance, item=None, container=None):
00060         if hasattr(aq_base(instance), 'demarshall_hook'):
00061             delattr(instance, 'demarshall_hook')
00062         if hasattr(aq_base(instance), 'marshall_hook'):
00063             delattr(instance, 'marshall_hook')

def Marshall.handlers.base.Marshaller.demarshall (   self,
  instance,
  data,
  kwargs 
)

Definition at line 64 of file base.py.

00064 
00065     def demarshall(self, instance, data, **kwargs):
00066         raise NotImplemented

def Marshall.handlers.base.Marshaller.initializeField (   self,
  instance,
  field 
)

Definition at line 70 of file base.py.

00070 
00071     def initializeField(self, instance, field):
00072         pass

def Marshall.handlers.base.Marshaller.initializeInstance (   self,
  instance,
  item = None,
  container = None 
)

Definition at line 48 of file base.py.

00048 
00049     def initializeInstance(self, instance, item=None, container=None):
00050         dm_hook = None
00051         m_hook = None
00052         if self.demarshall_hook is not None:
00053             dm_hook = getattr(instance, self.demarshall_hook, None)
00054         if self.marshall_hook is not None:
00055             m_hook = getattr(instance, self.marshall_hook, None)
00056         instance.demarshall_hook = dm_hook
00057         instance.marshall_hook = m_hook

def Marshall.handlers.base.Marshaller.marshall (   self,
  instance,
  kwargs 
)

Definition at line 67 of file base.py.

00067 
00068     def marshall(self, instance, **kwargs):
00069         raise NotImplemented


Member Data Documentation

Marshall.handlers.base.Marshaller.__implements__ = IMarshall,ILayer [static, private]

Definition at line 38 of file base.py.

Definition at line 45 of file base.py.

Definition at line 46 of file base.py.

tuple Marshall.handlers.base.Marshaller.security = ClassSecurityInfo() [static]

Definition at line 40 of file base.py.


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