try: from Interface import Interface except ImportError: # for Zope versions before 2.6.0 from Interface import Base as Interface class IRepresentable(Interface): """ Interface for representable content. """ def isRepresentation(): """ return True if this object is used as representation, 0 otherwise """ def addRepresentation(**kwargs): """ Add a new representation of this content. """ def removeRepresentation(repr_id): """ Removes a representation. """ def getRepresentation(repr_id): """ Return an object that is a representation of self """ def getRepresentations(): """ Return a list of (object, wf_state) """ def isCanonicalRepresentation(): """ boolean, is this the first representation of the content. """ def getCanonicalRepresentation(): """ Return the first representation of this content. """ def initializeRepresentation(): """ Initializes the object as a representation, would typically be called by addRepresentation. """