[Zope3-checkins] SVN: Zope3/branches/jim-adapter/src/zope/app/authentication/authentication.py Added a registrationManager property for backward compatibility.

Jim Fulton jim at zope.com
Wed Apr 26 14:49:25 EDT 2006


Log message for revision 67623:
  Added a registrationManager property for backward compatibility.
  

Changed:
  U   Zope3/branches/jim-adapter/src/zope/app/authentication/authentication.py

-=-
Modified: Zope3/branches/jim-adapter/src/zope/app/authentication/authentication.py
===================================================================
--- Zope3/branches/jim-adapter/src/zope/app/authentication/authentication.py	2006-04-26 17:34:06 UTC (rev 67622)
+++ Zope3/branches/jim-adapter/src/zope/app/authentication/authentication.py	2006-04-26 18:49:25 UTC (rev 67623)
@@ -40,6 +40,16 @@
         super(PluggableAuthentication, self).__init__()
         self.prefix = prefix
 
+    @property
+    def registrationManager(self):
+        import warnings
+        warnings.warn(
+            "The registration manager is deprecated and will go away in "
+            "Zope 3.5.  Use the simpler registration api (registerUtility) "
+            "instead.",
+            DeprecationWarning, 2)
+        return self.__parent__.registrationManager
+
     def _plugins(self, names, interface):
         for name in names:
             plugin = self.get(name)



More information about the Zope3-Checkins mailing list