[Zope-CVS] CVS: Products/Ape/lib/apelib/core - interfaces.py:1.12

Shane Hathaway shane at zope.com
Wed Mar 17 19:12:31 EST 2004


Update of /cvs-repository/Products/Ape/lib/apelib/core
In directory cvs.zope.org:/tmp/cvs-serv26272

Modified Files:
	interfaces.py 
Log Message:
Made compatible with Zope 3 interfaces.


=== Products/Ape/lib/apelib/core/interfaces.py 1.11 => 1.12 ===
--- Products/Ape/lib/apelib/core/interfaces.py:1.11	Tue Feb 17 00:25:11 2004
+++ Products/Ape/lib/apelib/core/interfaces.py	Wed Mar 17 19:12:30 2004
@@ -101,9 +101,9 @@
 class IDatabaseInitEvent (Interface):
     """Interface for events involved in initializing databases."""
 
-    connections = Attribute(__doc__="A mapping of database connections")
+    connections = Attribute("connections", "A mapping of database connections")
 
-    clear_all = Attribute(__doc__="""True if the database is to be cleared.
+    clear_all = Attribute("clear_all", """True to clear the database.
 
     This attribute is designed for testing purposes.
     """)
@@ -112,19 +112,19 @@
 class IMapperEvent (Interface):
     """The base interface for events occurring in context of a mapper."""
 
-    conf = Attribute(__doc__="The IMapperConfiguration")
+    conf = Attribute("conf", "The IMapperConfiguration")
 
-    mapper = Attribute(__doc__="The IMapper")
+    mapper = Attribute("mapper", "The IMapper")
 
-    oid = Attribute(__doc__="The OID of the object being mapped")
+    oid = Attribute("oid", "The OID of the object being mapped")
 
 
 class IGatewayEvent (IMapperEvent):
     """Interface for events used by gateways."""
 
-    connections = Attribute(__doc__="A mapping of database connections")
+    connections = Attribute("connections", "A mapping of database connections")
 
-    classification = Attribute(__doc__="The classification of the object.")
+    classification = Attribute("classification", "The classification of the object.")
 
 
 class ILoadEvent (IGatewayEvent):
@@ -138,7 +138,7 @@
 class IStoreEvent (IGatewayEvent):
     """Interface for events involved in storing objects."""
 
-    is_new = Attribute(__doc__="""True if the object is new.
+    is_new = Attribute("is_new", """True if the object is new.
 
     When this attribute is true, gateways should not overwrite
     existing data but instead raise an OIDConflictError if something
@@ -150,13 +150,13 @@
 class ISDEvent (IMapperEvent):
     """Base for serialization and deserialization events."""
 
-    obj_db = Attribute(__doc__="The relevant object database")
+    obj_db = Attribute("obj_db", "The relevant object database")
 
-    obj = Attribute(__doc__="The object being (de)serialized.")
+    obj = Attribute("obj", "The object being (de)serialized.")
 
-    serializer_name = Attribute(__doc__="The serializer in use.")
+    serializer_name = Attribute("serializer_name", "The serializer in use.")
 
-    upos = Attribute(__doc__="""The list of unmanaged persistent objects.
+    upos = Attribute("upos", """The list of unmanaged persistent objects.
 
     If no attention is paid to unmanaged persistent objects (UPOs),
     they will not notify ZODB when they are changed, and hence can be
@@ -164,7 +164,7 @@
     so that ZODB will see changes made to them and save the
     corresponding managed persistent object.""")
     
-    external = Attribute(__doc__="""The list of external oids.
+    external = Attribute("external", """The list of external oids.
 
     The list is built up during (de)serialization.  It contains
     [(oid, subobject)].""")
@@ -261,7 +261,7 @@
 class ISerializer(Interface):
     """Object serializer / deserializer"""
 
-    schema = Attribute(__doc__="The schema used by this component.")
+    schema = Attribute("schema", "The schema used by this component.")
 
     def canSerialize(obj):
         """Returns true if this serializer can serialize the given object.
@@ -319,7 +319,7 @@
     by Martin Fowler.
     """
 
-    schema = Attribute(__doc__="The schema used by this component.")
+    schema = Attribute("schema", "The schema used by this component.")
 
     def load(event):
         """Loads data.
@@ -373,7 +373,7 @@
     The keys in classifications are implementation-dependent.
     """
 
-    gateway = Attribute(__doc__="""The classification IGateway.
+    gateway = Attribute("gateway", """The classification IGateway.
 
     Classifiers load and store classifications using a gateway.  This
     attribute allows the system to store the classification of an
@@ -441,7 +441,7 @@
     one place.
     """
 
-    root_oid = Attribute(__doc__="The OID to use for the root")
+    root_oid = Attribute("root_oid", "The OID to use for the root")
 
     def new_oid(event, name, stored):
         """Returns a new oid.
@@ -459,11 +459,11 @@
 class IMapper (Interface):
     """A hub for mapping a certain kind of object.
     """
-    serializer = Attribute(__doc__="The IObjectSerializer for this mapper")
+    serializer = Attribute("serializer", "The IObjectSerializer for this mapper")
 
-    gateway = Attribute(__doc__="The IGateway for this mapper")
+    gateway = Attribute("gateway", "The IGateway for this mapper")
 
-    initializers = Attribute(__doc__="A list of IDatabaseInitializers")
+    initializers = Attribute("initializers", "A list of IDatabaseInitializers")
 
 
 class IConfigurableMapper (IMapper):
@@ -483,13 +483,13 @@
     """A configuration of mappers.
     """
 
-    mappers = Attribute(__doc__="Maps mapper name to IMapper")
+    mappers = Attribute("mappers", "Maps mapper name to IMapper")
 
-    classifier = Attribute(__doc__="The IClassifier")
+    classifier = Attribute("classifier", "The IClassifier")
 
-    oid_gen = Attribute(__doc__="The IOIDGenerator")
+    oid_gen = Attribute("oid_gen", "The IOIDGenerator")
 
-    initializers = Attribute(__doc__="A list of IDatabaseInitializers")
+    initializers = Attribute("initializers", "A list of IDatabaseInitializers")
 
     def check():
         """Verifies the configuration is sane.




More information about the Zope-CVS mailing list