[Zope3-checkins] CVS: Zope3/src/zope/app/component -
metaconfigure.py:1.23 metadirectives.py:1.11
Suresh Babu Eddala
sbabu at zeomega.com
Thu Dec 18 11:29:28 EST 2003
Update of /cvs-repository/Zope3/src/zope/app/component
In directory cvs.zope.org:/tmp/cvs-serv5077
Modified Files:
metaconfigure.py metadirectives.py
Log Message:
To Interface directive type(Interface type) attribute added
=== Zope3/src/zope/app/component/metaconfigure.py 1.22 => 1.23 ===
--- Zope3/src/zope/app/component/metaconfigure.py:1.22 Wed Dec 17 05:06:20 2003
+++ Zope3/src/zope/app/component/metaconfigure.py Thu Dec 18 11:28:57 2003
@@ -57,12 +57,15 @@
method=getattr(getServiceManager(None), methodName)
method(*args, **kwargs)
-def interface(_context, interface):
+def interface(_context, interface, type=None):
+ if type is not None:
+ zope.interface.directlyProvides(interface, type)
_context.action(
discriminator = None,
callable = handler,
args = (Interfaces, 'provideInterface', '', interface)
)
+
def proxify(ob, checker):
"""Try to get the object proxied with the checker, but not too soon
=== Zope3/src/zope/app/component/metadirectives.py 1.10 => 1.11 ===
--- Zope3/src/zope/app/component/metadirectives.py:1.10 Wed Dec 17 10:37:12 2003
+++ Zope3/src/zope/app/component/metadirectives.py Thu Dec 18 11:28:57 2003
@@ -133,6 +133,11 @@
required=True
)
+ type = GlobalObject(
+ title=u"Interface type",
+ required=False
+ )
+
class IAdapterDirective(Interface):
"""
Register an adapter
More information about the Zope3-Checkins
mailing list