Back to index

plone3  3.1.7
Public Member Functions
CMFEditions.interfaces.IStorage.IStorage Class Reference
Inheritance diagram for CMFEditions.interfaces.IStorage.IStorage:
Inheritance graph
[legend]
Collaboration diagram for CMFEditions.interfaces.IStorage.IStorage:
Collaboration graph
[legend]

List of all members.

Public Member Functions

def isRegistered
def register
def save
def retrieve
def getHistory
def getModificationDate

Detailed Description

Manages Storing and Retrieving Version to and from the Storage

Every resource has it's own history.

Definition at line 33 of file IStorage.py.


Member Function Documentation

Return the history of an object by the given history id.

Returns a 'IHistory' object.

Definition at line 95 of file IStorage.py.

00095 
00096     def getHistory(history_id):
00097         """Return the history of an object by the given history id.
00098 
00099         Returns a 'IHistory' object.
00100         """

Here is the caller graph for this function:

def CMFEditions.interfaces.IStorage.IStorage.getModificationDate (   history_id,
  selector = None 
)
Returns the modification date of the selected version of object
    which has the given history id.

If selected is None, the most recent version (HEAD) is taken.

Definition at line 101 of file IStorage.py.

00101 
00102     def getModificationDate(history_id, selector=None):
00103         """ Returns the modification date of the selected version of object
00104             which has the given history id.
00105 
00106         If selected is None, the most recent version (HEAD) is taken.
00107         """
00108 

Manages Storing and Retrieving Version to and from the Storage

Every resource has it's own history.
Returns True if the object is already registered.

A registered object has a history.

Definition at line 39 of file IStorage.py.

00039 
00040     def isRegistered(history_id):
00041         """Returns True if the object is already registered.
00042 
00043         A registered object has a history.
00044         """

Here is the caller graph for this function:

def CMFEditions.interfaces.IStorage.IStorage.register (   history_id,
  object,
  referenced_data = {},
  metadata = {} 
)
Sets up a new history for the object and does the first save.

The 'object' and the 'referenced_data' together contain the whole
data to be added to the history.

'object' is already a clone and needn't be cloned anymore before
beeing added to the history. Data in 'referenced_data' are direct
references to the original object and must be cloned before being
added to the history.

'referenced_data' is a list or tuple of python references or
'IStreamableReference' objects.

'metadata' must be a (nested) dictionary. If a 'comment' key exists
the implementation may assume it is a human readable string.

May veto the registering proces by raising a 'StorageError'
exception. No action is performed on repeated registering.

Returns the value of the newest version(selector).

Definition at line 45 of file IStorage.py.

00045 
00046     def register(history_id, object, referenced_data={}, metadata={}):
00047         """Sets up a new history for the object and does the first save.
00048 
00049         The 'object' and the 'referenced_data' together contain the whole
00050         data to be added to the history.
00051 
00052         'object' is already a clone and needn't be cloned anymore before
00053         beeing added to the history. Data in 'referenced_data' are direct
00054         references to the original object and must be cloned before being
00055         added to the history.
00056 
00057         'referenced_data' is a list or tuple of python references or
00058         'IStreamableReference' objects.
00059 
00060         'metadata' must be a (nested) dictionary. If a 'comment' key exists
00061         the implementation may assume it is a human readable string.
00062 
00063         May veto the registering proces by raising a 'StorageError'
00064         exception. No action is performed on repeated registering.
00065 
00066         Returns the value of the newest version(selector).
00067         """

Here is the caller graph for this function:

def CMFEditions.interfaces.IStorage.IStorage.retrieve (   history_id,
  selector 
)
Returns a selected version of an object, which has the given
   history id.

Returns a 'IVersionData' object.

Definition at line 88 of file IStorage.py.

00088 
00089     def retrieve(history_id, selector):
00090         """Returns a selected version of an object, which has the given
00091            history id.
00092 
00093         Returns a 'IVersionData' object.
00094         """

Here is the caller graph for this function:

def CMFEditions.interfaces.IStorage.IStorage.save (   history_id,
  object,
  referenced_data = {},
  metadata = {} 
)
Appends an object current state to a history.

The 'object' and the 'referenced_data' together contain the whole
data to be added to the history.

'object' is already a clone and needn't be cloned anymore before
beeing added to the history. Data in 'referenced_data' are direct
references to the original object and must be cloned before being
added to the history.

'referenced_data' is a list or tuple of python references or
'IStreamableReference' objects.

'metadata' must be a (nested) dictionary. If a 'comment' key exists
the implementation may assume it is a human readable string.

Returns the value of the newest version(selector).

Definition at line 68 of file IStorage.py.

00068 
00069     def save(history_id, object, referenced_data={}, metadata={}):
00070         """Appends an object current state to a history.
00071 
00072         The 'object' and the 'referenced_data' together contain the whole
00073         data to be added to the history.
00074 
00075         'object' is already a clone and needn't be cloned anymore before
00076         beeing added to the history. Data in 'referenced_data' are direct
00077         references to the original object and must be cloned before being
00078         added to the history.
00079 
00080         'referenced_data' is a list or tuple of python references or
00081         'IStreamableReference' objects.
00082 
00083         'metadata' must be a (nested) dictionary. If a 'comment' key exists
00084         the implementation may assume it is a human readable string.
00085 
00086         Returns the value of the newest version(selector).
00087         """

Here is the caller graph for this function:


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