Commit f2f140e2 authored by Evan Simpson's avatar Evan Simpson

Changed object* methods to declareObject* and updated docstrings.

parent 1142f28b
......@@ -163,19 +163,19 @@ class SecurityInfo(Acquisition.Implicit):
"""Declare names to be associated with a permission."""
self._setaccess(names, permission_name)
objectPublic__roles__=ACCESS_PRIVATE
def objectPublic(self):
"""Declare names to be publicly accessible."""
declareObjectPublic__roles__=ACCESS_PRIVATE
def declareObjectPublic(self):
"""Declare the object to be publicly accessible."""
self._setaccess((), ACCESS_PUBLIC)
objectPrivate__roles__=ACCESS_PRIVATE
def objectPrivate(self):
"""Declare names to be inaccessible to restricted code."""
declareObjectPrivate__roles__=ACCESS_PRIVATE
def declareObjectPrivate(self):
"""Declare the object to be inaccessible to restricted code."""
self._setaccess((), ACCESS_PRIVATE)
objectProtected__roles__=ACCESS_PRIVATE
def objectProtected(self, permission_name):
"""Declare names to be associated with a permission."""
declareObjectProtected__roles__=ACCESS_PRIVATE
def declareObjectProtected(self, permission_name):
"""Declare the object to be associated with a permission."""
self._setaccess((), permission_name)
setDefaultRoles__roles__=ACCESS_PRIVATE
......@@ -313,6 +313,11 @@ class ModuleSecurityInfo(SecurityInfo):
"""Cannot declare module names protected."""
pass
declareObjectProtected__roles__=ACCESS_PRIVATE
def declareObjectProtected(self, permission_name):
"""Cannot declare module protected."""
pass
setDefaultRoles__roles__=ACCESS_PRIVATE
def setDefaultRoles(self, permission_name, roles):
"""Cannot set default roles for permissions in a module."""
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment