[Zope-CVS] SVN: zversioning/trunk/src/versioning/interfaces.py
another version of our ongoing work on the interfaces
Grégoire Weber
zope.org at incept.ch
Tue Oct 12 12:06:07 EDT 2004
Log message for revision 28013:
another version of our ongoing work on the interfaces
Changed:
U zversioning/trunk/src/versioning/interfaces.py
-=-
Modified: zversioning/trunk/src/versioning/interfaces.py
===================================================================
--- zversioning/trunk/src/versioning/interfaces.py 2004-10-12 16:02:55 UTC (rev 28012)
+++ zversioning/trunk/src/versioning/interfaces.py 2004-10-12 16:06:06 UTC (rev 28013)
@@ -69,7 +69,7 @@
"""Top level API for a copy-modify-merge (subversion like) repository.
"""
- def saveAsVersion(obj):
+ def saveAsVersion(obj, metadata=None):
"""Save the current state of the object for later retreival.
"""
@@ -86,7 +86,7 @@
"""Marks the object as checked out (being in use somehow).
"""
- def checkin(obj):
+ def checkin(obj, metadata=None):
"""Check in the current state of an object.
Raises an RepositoryError if the object is not versionable.
@@ -116,14 +116,18 @@
does). Instead it returns the version as new object.
"""
- def getVersionIds(self, obj)
- """Returns references to all versions of the passed object.
+ def getVersionIds(self, obj):
+ """Returns all versions of the given object.
XXX Naming: Should we name that 'listVersions' just returning
references to the objects?
"""
+ def listMetadata(self, obj):
+ """Returns the metadata of all versions of the given object.
+ """
+
class ICheckoutAware(Interfaces):
"""Marking objects as checked in or checked out.
@@ -156,16 +160,24 @@
XXX Explain that this is a multidapter?
"""
+ def writeAspects():
+ """Write an aspect from the original object.
+ """
+
def updateAspects(selector):
"""Updates a certain aspect on the original object.
XXX exceptions?
XXX Should reading only certain parts of an aspect be possible?
+ E.g. to avoid reading a big blob?
+ XXX Probably the implementation has to handle lazy reading
+ of only parts of an aspect.
"""
- def writeAspects():
- """Write an aspect from the original object.
+ def readAspects(selector):
"""
+ """
+
class ITicket(Interface) :
""" A marker interface for access information for versioned data.
@@ -197,14 +209,14 @@
XXX YAGNI?
"""
- def getObject
-
def getVersion(history, selector):
"""
"""
-
+
+
class IPythonReferenceStorage :
- """ Marker interface for a storage that is able to preserve
+ """ XXX Do we need that? No!
+ Marker interface for a storage that is able to preserve
python references and thus is able to accept originals.
A minimal implementation would only ensure that versioned originals
More information about the Zope-CVS
mailing list