[CMF-checkins] CVS: CMF/CMFCore/interfaces -
portal_memberdata.py:1.9 portal_membership.py:1.8
Yvo Schubbe
schubbe at web.de
Wed Sep 24 06:02:45 EDT 2003
Update of /cvs-repository/CMF/CMFCore/interfaces
In directory cvs.zope.org:/tmp/cvs-serv1184/CMFCore/interfaces
Modified Files:
portal_memberdata.py portal_membership.py
Log Message:
Merged yuppie-deleteMembers-branch:
- Added deleteMemberData, deleteMemberArea and deleteLocalRoles.
- Added 'recursive' argument to deleteLocalRoles.
- Renamed createMemberarea to createMemberArea.
- Moved getMembersFolder to CMFCore.
- Added CMFCoreExceptions.py.
- Added 'Change local roles' Permission.
=== CMF/CMFCore/interfaces/portal_memberdata.py 1.8 => 1.9 ===
--- CMF/CMFCore/interfaces/portal_memberdata.py:1.8 Mon Sep 1 11:18:35 2003
+++ CMF/CMFCore/interfaces/portal_memberdata.py Wed Sep 24 06:02:14 2003
@@ -47,23 +47,46 @@
The result is designed to be iterated over in a dtml-in
'''
- ## pruneMemberDataContents__roles__ = () # Private.
def pruneMemberDataContents():
- '''
- Compare the user IDs stored in the member data
- tool with the list in the actual underlying acl_users
- and delete anything not in acl_users
- '''
+ """ Delete member data of all members not listet in acl_users.
+
+ Compare the user IDs stored in the member data tool with the list in
+ the actual underlying acl_users and delete anything not in acl_users.
+
+ Permission -- Python only
+ """
- ## searchMemberData__roles__ = () # Private.
def searchMemberData(search_param, search_term, attributes=()):
- '''
+ """ Search members.
+
Returns a sequence of dictionaries containing data for members
that match the query as expressed by search_param and search_term.
The contents of each member data mapping can be influenced by
passing in a sequence of desired attributes, by default the only
data returned is the username and the email address.
- '''
+
+ Permission -- Python only
+
+ Returns -- Sequence of dictionaries
+ """
+
+ def registerMemberData(m, id):
+ """ Add the given member data to the _members btree.
+
+ This is done as late as possible to avoid side effect transactions and
+ to reduce the necessary number of entries.
+
+ Permission -- Python only
+ """
+
+ def deleteMemberData(member_id):
+ """ Delete member data of specified member.
+
+ Permission -- Python only
+
+ Returns -- Boolean value
+ """
+
class MemberData(Interface):
""" MemberData interface.
=== CMF/CMFCore/interfaces/portal_membership.py 1.7 => 1.8 ===
--- CMF/CMFCore/interfaces/portal_membership.py:1.7 Mon Jun 2 12:18:47 2003
+++ CMF/CMFCore/interfaces/portal_membership.py Wed Sep 24 06:02:14 2003
@@ -68,6 +68,17 @@
Permission -- Always available
"""
+ def getMembersFolder():
+ """ Get the members folder object.
+
+ If no members folder is set or the set folder id doesn't exist, None
+ is returned.
+
+ Permission -- Always available
+
+ Returns -- Members folder object or None
+ """
+
def getHomeFolder(id=None, verifyPermission=0):
"""Returns a member's home folder object or None.
Set verifyPermission to 1 to return None when the user
@@ -115,6 +126,19 @@
Permission -- Python only
"""
+ def deleteMembers(member_ids, delete_memberareas=1, delete_localroles=1):
+ """ Delete members specified by member_ids.
+
+ Delete members in acl_users and member data in portal_memberdata.
+ If delete_memberareas is true, delete members' home folders including
+ all content items. If delete_localroles is true, recursively delete
+ members' local roles, starting from the portal root.
+
+ Permission -- Manage users
+
+ Returns -- Tuple listing member_ids of deleted members
+ """
+
def getPortalRoles():
"""
Return all local roles defined by the portal itself,
@@ -160,10 +184,22 @@
Permission -- Manage portal
"""
- def createMemberarea(member_id=''):
+ def createMemberArea(member_id=''):
""" Create a member area for 'member_id' or authenticated user.
Permission -- Always available
Returns -- created member folder object or None
+ """
+
+ def createMemberarea(member_id=''):
+ """ Deprecated alias of createMemberArea.
+ """
+
+ def deleteMemberArea(member_id):
+ """ Delete member area of member specified by member_id.
+
+ Permission -- Manage users
+
+ Returns -- Boolean value
"""
More information about the CMF-checkins
mailing list