[Zope3-checkins] CVS: Zope3/src/zope/app/security/registries - permissionregistry.py:1.4.18.1 principalregistry.py:1.7.18.1 registeredobject.py:1.2.26.1 roleregistry.py:1.4.18.1

Grégoire Weber zope@i-con.ch
Sun, 22 Jun 2003 10:23:56 -0400


Update of /cvs-repository/Zope3/src/zope/app/security/registries
In directory cvs.zope.org:/tmp/cvs-serv24874/src/zope/app/security/registries

Modified Files:
      Tag: cw-mail-branch
	permissionregistry.py principalregistry.py registeredobject.py 
	roleregistry.py 
Log Message:
Synced up with HEAD

=== Zope3/src/zope/app/security/registries/permissionregistry.py 1.4 => 1.4.18.1 ===
--- Zope3/src/zope/app/security/registries/permissionregistry.py:1.4	Tue Mar 11 11:11:17 2003
+++ Zope3/src/zope/app/security/registries/permissionregistry.py	Sun Jun 22 10:23:25 2003
@@ -24,15 +24,15 @@
 from zope.security.checker import CheckerPublic
 from zope.app.security.exceptions import UndefinedPermissionError
 from zope.app.interfaces.services.service import ISimpleService
-
+from zope.interface import implements
 
 
 class Permission(RegisteredObject):
-    __implements__ = IPermission
+    implements(IPermission)
 
 
 class PermissionRegistry(Registry):
-    __implements__ = IPermissionService, ISimpleService
+    implements(IPermissionService, ISimpleService)
 
     def __init__(self, prefix=PREFIX):
         Registry.__init__(self, Permission)


=== Zope3/src/zope/app/security/registries/principalregistry.py 1.7 => 1.7.18.1 ===
--- Zope3/src/zope/app/security/registries/principalregistry.py:1.7	Tue Mar 11 11:11:17 2003
+++ Zope3/src/zope/app/security/registries/principalregistry.py	Sun Jun 22 10:23:25 2003
@@ -23,13 +23,14 @@
 from zope.app.interfaces.security import IAuthenticationService, IPrincipal
 from zope.app.interfaces.security import IUnauthenticatedPrincipal
 from zope.app.interfaces.services.service import ISimpleService
+from zope.interface import implements
 
 class DuplicateLogin(Exception): pass
 class DuplicateId(Exception): pass
 
 class PrincipalRegistry:
 
-    __implements__ = IAuthenticationService, ISimpleService
+    implements(IAuthenticationService, ISimpleService)
 
     # Methods implementing IAuthenticationService
 
@@ -133,13 +134,10 @@
     def getDescription(self):
         return self.__description
 
-    def getRoles(self):
-        return ()
-
 
 class Principal(PrincipalBase):
 
-    __implements__ = IPrincipal
+    implements(IPrincipal)
 
     def __init__(self, id, title, description, login, pw):
         super(Principal, self).__init__(id, title, description)
@@ -155,4 +153,4 @@
 
 class UnauthenticatedPrincipal(PrincipalBase):
 
-    __implements__ = IUnauthenticatedPrincipal
+    implements(IUnauthenticatedPrincipal)


=== Zope3/src/zope/app/security/registries/registeredobject.py 1.2 => 1.2.26.1 ===
--- Zope3/src/zope/app/security/registries/registeredobject.py:1.2	Wed Dec 25 09:13:17 2002
+++ Zope3/src/zope/app/security/registries/registeredobject.py	Sun Jun 22 10:23:25 2003
@@ -14,9 +14,10 @@
 """An implementation of things that can be registered in a Registry."""
 
 from zope.app.interfaces.security import IRegisteredObject
+from zope.interface import implements
 
 class RegisteredObject(object):
-    __implements__ = IRegisteredObject
+    implements(IRegisteredObject)
 
     def __init__(self, id, title, description):
         self._id = id


=== Zope3/src/zope/app/security/registries/roleregistry.py 1.4 => 1.4.18.1 ===
--- Zope3/src/zope/app/security/registries/roleregistry.py:1.4	Tue Mar 11 11:11:17 2003
+++ Zope3/src/zope/app/security/registries/roleregistry.py	Sun Jun 22 10:23:25 2003
@@ -20,13 +20,14 @@
 from zope.app.interfaces.security import IRole
 from zope.app.interfaces.security import IRoleService
 from zope.app.interfaces.services.service import ISimpleService
+from zope.interface import implements
 
 class Role(RegisteredObject):
-    __implements__ = IRole
+    implements(IRole)
 
 
 class RoleRegistry(Registry):
-    __implements__ = IRoleService, ISimpleService
+    implements(IRoleService, ISimpleService)
 
     def __init__(self, prefix=PREFIX):
         Registry.__init__(self, Role)