[Zope-Checkins] CVS: Zope3/lib/python/Zope/App/OFS - Folder.py:1.1.2.4 IContainer.py:1.1.2.2

Brian Lloyd brian@digicool.com
Fri, 16 Nov 2001 17:06:03 -0500


Update of /cvs-repository/Zope3/lib/python/Zope/App/OFS
In directory cvs.zope.org:/tmp/cvs-serv29378

Modified Files:
      Tag: Zope-3x-branch
	Folder.py IContainer.py 
Log Message:
Updated docs re: traversal and read collections


=== Zope3/lib/python/Zope/App/OFS/Folder.py 1.1.2.3 => 1.1.2.4 ===
 
     def objectIds(self):
-        """Return a sequence-like object containing the names of the
-           objects that appear in the container."""
+        """Return a sequence-like object containing the names associated 
+           with the objects that appear in the folder."""
         return self.data.keys()
 
     def objectValues(self):
         """Return a sequence-like object containing the objects that
-           appear in the container."""
+           appear in the folder."""
         return self.data.values()
 
     def objectItems(self):
         """Return a sequence-like object containing tuples of the form
-           (name, object) for the objects that appear in the container."""
+           (name, object) for the objects that appear in the folder."""
         return self.data.items()
 
     def getObject(self, name, default=None):
-        """Return the named object of the container, or the value of the
-           default if given. If no default is given and the named object
-           is not found, None is returned."""
+        """Return the named object of the container, or the default."""
         return self.data.get(name, default)
 
     def hasObject(self, name):
-        """Return true if the named object appears in the container."""
+        """Return true if the named object appears in the folder."""
         return self.data.has_key(name)
 
     def objectCount(self):
-        """Return the number of objects in the container."""
+        """Return the number of objects in the folder."""
         return len(self.data)
 
     def setObject(self, name, object):
-        """Add the given object to the container under the given name."""
+        """Add the given object to the folder under the given name."""
         self.data[name] = object
 
     def delObject(self, name):
-        """Delete the named object from the container. Raises a KeyError
+        """Delete the named object from the folder. Raises a KeyError
            if the object is not found."""
         del self.data[name]
 


=== Zope3/lib/python/Zope/App/OFS/IContainer.py 1.1.2.1 => 1.1.2.2 ===
        support the read-only semantics of a Python sequence (indexing,
        slicing, len). The return value is not, however, required to be an
-       actual native sequence type (list or tuple)."""
+       actual native sequence type (list or tuple).
+
+       Note that the IReadContainer interface implies a collection of
+       objects that are exposed via various publishing mechanisms.
+       Collections of object that *do not* want to be traversed
+       should not implement this."""
 
     def objectIds():
         """Return a sequence-like object containing the names of the