com.sap.workspaces.workspace

Interface IMemberList


public interface IMemberList

Provides tools for accessing workspace members


Method Summary
 void changeRole(com.sap.security.api.IUser user, com.sap.security.api.IPrincipal principal, WorkspaceRole currentRole, WorkspaceRole newRole)
          Changes the workspace role (PENDING/MEMBER/MANAGER) of a principal (user or group) Enables the following scenarios: Approve pending request and add as managers: currentRole: WorkspaceRole.PENDING newRole: WorkspaceRole.MANAGER Approve pending request and add as members: currentRole: WorkspaceRole.PENDING newRole: WorkspaceRole.MEMBER Reject Pending request: currentRole: WorkspaceRole.PENDING newRole: null Change from manager to members: currentRole: WorkspaceRole.MANAGER newRole: WorkspaceRole.MEMBER Change from member to manager: currentRole: WorkspaceRole.MEMBER newRole: WorkspaceRole.MANAGER
 com.sap.security.api.IUser getOwner()
          Returns the workspace owner, or null if the owner does not exist
 IRole getRole(WorkspaceRole workspaceRole)
          Returns a workspace role of the specified type
 boolean isManager(com.sap.security.api.IUser user)
          Checks if the specified user is a manager in this workspace
 void setOwner(com.sap.security.api.IUser user, com.sap.security.api.IUser newOwner)
          Assigns workspace ownership
 

Method Detail

getRole

IRole getRole(WorkspaceRole workspaceRole)
Returns a workspace role of the specified type

Parameters:
workspaceRole - a workspace role type, such as MEMBER or MANAGER
Returns:
An object representing a workspace role of the specified type

getOwner

com.sap.security.api.IUser getOwner()
Returns the workspace owner, or null if the owner does not exist

Returns:
The workspace owner, or null if the owner does not exist

setOwner

void setOwner(com.sap.security.api.IUser user,
              com.sap.security.api.IUser newOwner)
              throws MemberListException
Assigns workspace ownership

Parameters:
user - the performing user who has appropriate permissions
newOwner - the user to whom the workspace ownership is assigned
Throws:
MemberListException - if the performing user does not have the appropriate permission

isManager

boolean isManager(com.sap.security.api.IUser user)
Checks if the specified user is a manager in this workspace

Parameters:
user - the user
Returns:
True if the user is a manager in this workspace

changeRole

void changeRole(com.sap.security.api.IUser user,
                com.sap.security.api.IPrincipal principal,
                WorkspaceRole currentRole,
                WorkspaceRole newRole)
                throws WorkspacesRuntimeException
Changes the workspace role (PENDING/MEMBER/MANAGER) of a principal (user or group) Enables the following scenarios: Approve pending request and add as managers: currentRole: WorkspaceRole.PENDING newRole: WorkspaceRole.MANAGER Approve pending request and add as members: currentRole: WorkspaceRole.PENDING newRole: WorkspaceRole.MEMBER Reject Pending request: currentRole: WorkspaceRole.PENDING newRole: null Change from manager to members: currentRole: WorkspaceRole.MANAGER newRole: WorkspaceRole.MEMBER Change from member to manager: currentRole: WorkspaceRole.MEMBER newRole: WorkspaceRole.MANAGER

Parameters:
user - the workspace manager or owner
principal - the principal
currentRole - the current role
newRole - the new role
Throws:
WorkspacesRuntimeException
Since:
1.1 SP02


Copyright 2012 SAP AG Complete Copyright Notice