[Zope3-checkins] CVS: Zope3/src/zope/app/interfaces/utilities - schema.py:1.5

Sidnei da Silva cvs-admin at zope.org
Wed Nov 12 13:47:03 EST 2003


Update of /cvs-repository/Zope3/src/zope/app/interfaces/utilities
In directory cvs.zope.org:/tmp/cvs-serv28091/src/zope/app/interfaces/utilities

Modified Files:
	schema.py 
Log Message:
Simplify a bit moveField. Add missing interface methods. Add a few more tests to make sure moving up works correctly (it wasn't before this change).


=== Zope3/src/zope/app/interfaces/utilities/schema.py 1.4 => 1.5 ===
--- Zope3/src/zope/app/interfaces/utilities/schema.py:1.4	Fri Oct 31 09:57:09 2003
+++ Zope3/src/zope/app/interfaces/utilities/schema.py	Wed Nov 12 13:46:31 2003
@@ -69,6 +69,23 @@
         number larger than len(self), then an error is raised.
         """
 
+    def moveField(name, position):
+        """Move a field (given by its name) to a particular position.
+
+        If the position does not make sense, i.e. a negative number of a
+        number larger than len(self), then an error is raised.
+        """
+
+    def __setitem__(name, object):
+        """Add the given object to the container under the given name.
+        """
+
+    def __delitem__(name):
+        """Delete the nameed object from the container.
+
+        Raises a KeyError if the object is not found.
+        """
+
 class IMutableSchema(IReadMutableSchema, IWriteMutableSchema):
     """This object represents an interface/schema that can be edited by
     managing the fields it contains."""




More information about the Zope3-Checkins mailing list