[Zope3-checkins] CVS: Zope3/src/zope/app/browser/cache - configure.zcml:1.4

Jim Fulton jim@zope.com
Tue, 31 Dec 2002 13:27:22 -0500


Update of /cvs-repository/Zope3/src/zope/app/browser/cache
In directory cvs.zope.org:/tmp/cvs-serv1916/src/zope/app/browser/cache

Modified Files:
	configure.zcml 
Log Message:
Hold on to your butts! :)

In an effort to make zcml view definitions even easier to understand
(see 
http://dev.zope.org/Wikis/DevSite/Projects/ComponentArchitecture/ZCMLBrowserViewDirectiveSimplification
)

I've finished a long-overdue refactoring of the configuration
directives for defining views. The logic is now a good bit less
complicated. 

I also simplified the way security assertions on views were
handled. To make this work right, I had to fix a bug in the
publication machinery. Now, as objects are traversed, the results of
traversal are put in security proxies.  This is really necessary to
treat URLs as "untrusted code", which they are.

I updated the meta-configuration directives for views and ran the zcml
documentation utility, so there is now documentation for the (new)
view directives. See the files 'page', 'pages', and 'view', in 
'doc/zcml/namespaces.zope.org/browser'.

I feel these changes are highly desireable for the alpha, but they are
significant enough that the chance of breakage is a lot higher than
I'd like just before the alpha.  I'd appreciate it if folks would let
me know if I've broken anything.



=== Zope3/src/zope/app/browser/cache/configure.zcml 1.3 => 1.4 ===
--- Zope3/src/zope/app/browser/cache/configure.zcml:1.3	Thu Dec 26 17:11:52 2002
+++ Zope3/src/zope/app/browser/cache/configure.zcml	Tue Dec 31 13:26:51 2002
@@ -8,14 +8,14 @@
       title="RAM Cache" action="zope.app.caching.RAMCache"
       description="RAM Cache"/>
 
-  <browser:view for="zope.app.interfaces.cache.ram.IRAMCache"
-		factory="zope.app.browser.cache.ram.RAMCacheView"
+  <browser:pages for="zope.app.interfaces.cache.ram.IRAMCache"
+		class="zope.app.browser.cache.ram.RAMCacheView"
 		permission="zope.Public"
 		>
     <browser:page name="editAction.html" attribute="action" />
-    <browser:page name="index.html"       template="edit.pt" />
-    <browser:page name="stats.html"      template="stats.pt" />
-  </browser:view>
+    <browser:page name="index.html"       template="ramedit.pt" />
+    <browser:page name="stats.html"      template="ramstats.pt" />
+  </browser:pages>
 
   <browser:menuItems menu="zmi_views"
      for="zope.app.interfaces.cache.ram.IRAMCache">
@@ -23,9 +23,9 @@
     <browser:menuItem title="Statistics" action="stats.html"/>
   </browser:menuItems>
 
-  <browser:view for="zope.app.interfaces.annotation.IAnnotatable"
+  <browser:pages for="zope.app.interfaces.annotation.IAnnotatable"
                 permission="zope.ManageBindings"
-                factory="zope.app.browser.cache.cacheable.CacheableView">
+                class="zope.app.browser.cache.cacheable.CacheableView">
 
     <browser:page name="Caching.html"
                   attribute="form" />
@@ -33,6 +33,6 @@
                   attribute="action" />
     <browser:page name="InvalidateCache.html"
                   attribute="invalidate" />
-  </browser:view>
+  </browser:pages>
 
 </zopeConfigure>