[Zope3-checkins] CVS: Zope3/src/zope/app/publisher/xmlrpc - metaconfigure.py:1.15.12.1

Jim Fulton cvs-admin at zope.org
Sun Nov 9 11:08:55 EST 2003


Update of /cvs-repository/Zope3/src/zope/app/publisher/xmlrpc
In directory cvs.zope.org:/tmp/cvs-serv15349/src/zope/app/publisher/xmlrpc

Modified Files:
      Tag: adaptergeddon-branch
	metaconfigure.py 
Log Message:
Created a global presentation service that replaces the 
global view, resource, and skin services.

Now look up presentation components by adapting from a request type,
rather than adapting to a presentation type.





=== Zope3/src/zope/app/publisher/xmlrpc/metaconfigure.py 1.15 => 1.15.12.1 ===
--- Zope3/src/zope/app/publisher/xmlrpc/metaconfigure.py:1.15	Sun Aug 17 02:07:39 2003
+++ Zope3/src/zope/app/publisher/xmlrpc/metaconfigure.py	Sun Nov  9 11:08:24 2003
@@ -15,10 +15,12 @@
 
 $Id$
 """
+
+from zope.component.servicenames import Presentation
 from zope.app.component.metaconfigure import handler
 from zope.app.services.servicenames import Interfaces
 from zope.configuration.exceptions import ConfigurationError
-from zope.publisher.interfaces.xmlrpc import IXMLRPCPresentation
+from zope.publisher.interfaces.xmlrpc import IXMLRPCRequest
 from zope.security.checker import CheckerPublic, Checker
 
 
@@ -68,10 +70,10 @@
 
     # Register the new view.
     _context.action(
-        discriminator = ('view', for_, name, IXMLRPCPresentation),
+        discriminator = ('view', for_, name, IXMLRPCRequest),
         callable = handler,
-        args = ('Views', 'provideView', for_, name,
-                IXMLRPCPresentation, [class_]) )
+        args = (Presentation, 'provideView', for_, name,
+                IXMLRPCRequest, [class_]) )
 
     # Register the used interfaces with the interface service
     if for_ is not None:
@@ -86,7 +88,7 @@
 def defaultView(_context, name, for_=None):
     """Declare the view having the passed name as the default view."""
     _context.action(
-        discriminator = ('defaultViewName', for_, IXMLRPCPresentation, name),
+        discriminator = ('defaultViewName', for_, IXMLRPCRequest, name),
         callable = handler,
-        args = ('Views', 'setDefaultViewName', for_, IXMLRPCPresentation, name)
+        args = (Presentation, 'setDefaultViewName', for_, IXMLRPCRequest, name)
         )




More information about the Zope3-Checkins mailing list