[Zope3-checkins] CVS: Zope3/lib/python/Zope/ComponentArchitecture - IAdapterService.py:1.4

Jim Fulton jim@zope.com
Thu, 19 Dec 2002 14:39:16 -0500


Update of /cvs-repository/Zope3/lib/python/Zope/ComponentArchitecture
In directory cvs.zope.org:/tmp/cvs-serv19593

Modified Files:
	IAdapterService.py 
Log Message:
Added getRegisteredMatching (introspection) to interface.

This still needs to be updated to work with names.


=== Zope3/lib/python/Zope/ComponentArchitecture/IAdapterService.py 1.3 => 1.4 ===
--- Zope3/lib/python/Zope/ComponentArchitecture/IAdapterService.py:1.3	Sun Dec 15 15:16:38 2002
+++ Zope3/lib/python/Zope/ComponentArchitecture/IAdapterService.py	Thu Dec 19 14:39:15 2002
@@ -38,3 +38,24 @@
 
         The default will be returned if the component can't be found.
         """
+
+    # XXX need to add name support
+    def getRegisteredMatching(for_interfaces=None, provided_interfaces=None):
+        """Return information about registered data
+
+        Zero or more for and provided interfaces may be
+        specified. Registration information matching any of the
+        specified interfaces is returned.
+
+        The arguments may be interfaces, or sequences of interfaces.
+
+        The returned value is a sequence of three-element tuples:
+
+        - required interface
+
+        - provided interface
+
+        - the object registered specifically for the required and
+          provided interfaces.
+
+        """