wt.inf.team
Interface ContainerTeamService

All Known Implementing Classes:
StandardContainerTeamService

public interface ContainerTeamService

Methods for manipulating ContainerTeams

Supported API: true

Extendable: false


Method Summary
 ContainerTeamManaged activate(ContainerTeamManaged container)
          activate/start the ContainerTeamManaged object

Supported API: true
 void addGuestMember(ContainerTeam team, WTPrincipal principal)
          This method adds the principal to guest group.
 void addMember(ContainerTeam team, Role role, WTPrincipal principal)
          This method adds the user to the necessary groups in the containers that use the container team.
 wt.inf.team.ContainerTeamReference createContainerTeam(String name, OrgContainer orgContainer, String desc, TeamCategory category)
          Creates a new Container Team.
 wt.inf.team.ContainerTeamReference createContainerTeam(String name, OrgContainer orgContainer, String desc, TeamCategory category, boolean shared, boolean enabled, boolean extendable, String sharedTeamInvitationMsg, WTPrincipalReference creator)
          Creates a container team.
 List findContainersForTeam(ContainerTeam team)
          Returns a list of the ContainerTeamManaged objects that use the team.
 ContainerTeam getContainerTeam(ContainerTeamManaged container)
          Returns the container team for the specified container.
 String getRoleDescription(Role role, ContainerTeam team)
          

Supported API: true
 ContainerTeamManaged inactivate(ContainerTeamManaged container, ContainerTeamManagedState state)
          inactivate/suspend the ContainerTeamManaged object

Supported API: true
 void recomputeMembership(ContainerTeamManaged container)
          Synchs the ContainerTeamMembership with the LDAP groups.
 void recomputeMembership(WTGroup group)
          Synchs the ContainerTeamMembership with the LDAP groups.
 void removeGuestMember(ContainerTeam team, WTPrincipal principal)
          This method removes the principal from the guest group.
 void removeMember(ContainerTeam team, Role role, WTPrincipal principal)
          This method removed the user from the necessary groups in the containers that use the container team.
 void removeRole(ContainerTeam team, Role role)
          This method removes the user participating in the role from the necessary groups in the containers that use the container team.
 void replaceUser(wt.inf.team.ContainerTeamReference teamReference, WTUser replacedUser, WTUser newUser, boolean reassign, boolean removed)
          Replace the user in all containers that use the container team.
 wt.access.AdHocControlled setPrincipalAdHocAcl(ContainerTeamManaged container, wt.access.AdHocControlled per, Vector perms, WTPrincipal principal)
          Set the ad-hoc access rights for a given user or group.
 wt.access.AdHocControlled setRoleAdHocAcl(ContainerTeamManaged container, wt.access.AdHocControlled per, Vector perms, String roleName)
          Set the ad-hoc access rights for a given role in the container's team.
 void setRoleDescription(Role role, String description, ContainerTeam team)
          The description to assign to the role.
 void updateContainerTeam(ContainerTeam team)
          

Supported API: true
 

Method Detail

createContainerTeam

wt.inf.team.ContainerTeamReference createContainerTeam(String name,
                                                       OrgContainer orgContainer,
                                                       String desc,
                                                       TeamCategory category)
                                                       throws WTException
Creates a new Container Team.

Supported API: true

Parameters:
name - The name of the container team.
orgContainer - The OrgContainer where the container is being created.
desc - A description of the container team.
category - Enumerated TeamCategory value.
Returns:
ContainerTeamReference
Throws:
WTException

createContainerTeam

wt.inf.team.ContainerTeamReference createContainerTeam(String name,
                                                       OrgContainer orgContainer,
                                                       String desc,
                                                       TeamCategory category,
                                                       boolean shared,
                                                       boolean enabled,
                                                       boolean extendable,
                                                       String sharedTeamInvitationMsg,
                                                       WTPrincipalReference creator)
                                                       throws WTException
Creates a container team. This method replaces an older method of the same name, but now includes the 'shared', 'enabled', and 'extendable' attributes in the signature.

Supported API: true

Parameters:
name - The name of the container team.
orgContainer - The OrgContainer where the container is being created.
desc - A description of the container team.
category - Enumerated TeamCategory value.
shared - Indicates whether or not the team is shared.
enabled - Determines if the team can be put into use.
extendable - Gives the ability of a shared team to be extended locally.
sharedTeamInvitationMsg - If the team being created is shared, an invitation message is allowed to be passed in and will be set on the container team itself. This message will be sent out to users who are added to the shared team.
creator - Specifies the creator of the team. If this field is null, the current user will be used instead.
Returns:
ContainerTeamReference
Throws:
WTException

addMember

void addMember(ContainerTeam team,
               Role role,
               WTPrincipal principal)
               throws WTException
This method adds the user to the necessary groups in the containers that use the container team.

Supported API: true

Parameters:
team - The team where the participant should be added to the specified role.
role - The role where the participant will be added as a team member.
principal - The principal to be added to the role in the team.
Throws:
WTException

removeMember

void removeMember(ContainerTeam team,
                  Role role,
                  WTPrincipal principal)
                  throws WTException
This method removed the user from the necessary groups in the containers that use the container team.

Supported API: true

Parameters:
team - The team where the participant should be removed from the specified role.
role - The role where the participant will be removed as a team member.
principal - The principal to be removed from the role in the team.
Throws:
WTException

removeRole

void removeRole(ContainerTeam team,
                Role role)
                throws WTException
This method removes the user participating in the role from the necessary groups in the containers that use the container team.

Supported API: true

Parameters:
team - The team where the role and should be removed. Participants who do not belong to additional roles in the team will be removed completely from the container team.
role - The role that should be removed from the team.
Throws:
WTException

recomputeMembership

void recomputeMembership(ContainerTeamManaged container)
                         throws WTException
Synchs the ContainerTeamMembership with the LDAP groups.

Supported API: true

Parameters:
container - The container that should be synched with the team.
Throws:
WTException

recomputeMembership

void recomputeMembership(WTGroup group)
                         throws WTException
Synchs the ContainerTeamMembership with the LDAP groups.

Supported API: true

Parameters:
group -
Throws:
WTException

inactivate

ContainerTeamManaged inactivate(ContainerTeamManaged container,
                                ContainerTeamManagedState state)
                                throws WTException
inactivate/suspend the ContainerTeamManaged object

Supported API: true

Parameters:
container - the containerTeamManaged object to be inactiviated/suspended
state - the ContainerTeamManagedState that the inactivated container should be set to
Returns:
ContainerTeamManaged
Throws:
WTException

activate

ContainerTeamManaged activate(ContainerTeamManaged container)
                              throws WTException
activate/start the ContainerTeamManaged object

Supported API: true

Parameters:
container - the ContainerTeamManaged object to be activated/started
Returns:
ContainerTeamManaged
Throws:
WTException

getContainerTeam

ContainerTeam getContainerTeam(ContainerTeamManaged container)
                               throws WTException
Returns the container team for the specified container. A check is done to see if a local team exists, if so that team is returned, otherwise the shared team is returned, if one exists.

Supported API: true

Parameters:
container - The container of interest.
Returns:
ContainerTeam
Throws:
WTException

addGuestMember

void addGuestMember(ContainerTeam team,
                    WTPrincipal principal)
                    throws WTException
This method adds the principal to guest group.

Supported API: true

Parameters:
team - The team where the participant should be added to the specified role.
principal - The principal to be added to the role in the team.
Throws:
WTException

removeGuestMember

void removeGuestMember(ContainerTeam team,
                       WTPrincipal principal)
                       throws WTException
This method removes the principal from the guest group.

Supported API: true

Parameters:
team - The team where the participant should be removed from the specified role.
principal - The principal to be removed from the role in the team.
Throws:
WTException

replaceUser

void replaceUser(wt.inf.team.ContainerTeamReference teamReference,
                 WTUser replacedUser,
                 WTUser newUser,
                 boolean reassign,
                 boolean removed)
                 throws WTException
Replace the user in all containers that use the container team.

Supported API: true

Parameters:
teamReference - A reference to the ContainerTeam where the user should be replaced.
replacedUser - The user being replaced.
newUser - The user taking the place of the replaced user.
reassign - A flag that indicates whether or not ad hoc acls and object subscriptions should be assigned to the new user.
removed - This should be true if this was called as a result of the user being removed from the container. This boolean is needed to determine the message to display if the user cannot be removed due to checked out objects.
Throws:
WTException

setRoleAdHocAcl

wt.access.AdHocControlled setRoleAdHocAcl(ContainerTeamManaged container,
                                          wt.access.AdHocControlled per,
                                          Vector perms,
                                          String roleName)
                                          throws WTException
Set the ad-hoc access rights for a given role in the container's team. To remove all the ad-hoc access rights granted by the ProjectLink access ui or by this method previously, pass it an empty Vector of permissions. The object is returned after is has been saved.

Supported API: true

Parameters:
container - The Container for which the object is located in and for which to get the role from.
per - The object to set access on.
perms - a list of wt.access.AccessPermissions to grant to the role. If MODIFY is specified, a READ permission will be implicitly added as well. If the list is empty, all permissions will be removed for the role.
roleName - The role name that is used to find the container's role. Example, for out-of-the box roles, pass is all upper-case forms of the role name in english: "MANUFACTURER". For custom roles, pass in the string exactly as entered in the modify team ui: "my Custom Role".
Returns:
AdHocControlled
Throws:
WTException

setPrincipalAdHocAcl

wt.access.AdHocControlled setPrincipalAdHocAcl(ContainerTeamManaged container,
                                               wt.access.AdHocControlled per,
                                               Vector perms,
                                               WTPrincipal principal)
                                               throws WTException
Set the ad-hoc access rights for a given user or group. To remove all the ad-hoc access rights granted by the ProjectLink access ui or by this method previously, pass it an empty Vector of permissions. The object is returned after is has been saved.

Supported API: true

Parameters:
container - The Container for which the object is located in and for which to get the role from.
per - The object to set access on.
perms - a list of wt.access.AccessPermissions to grant to the role. If MODIFY is specified, a READ permission will be implicitly added as well. If the list is empty, all permissions will be removed for the role.
principal - The user or group that is getting the new access level.
Returns:
AdHocControlled
Throws:
WTException

findContainersForTeam

List findContainersForTeam(ContainerTeam team)
                           throws WTException
Returns a list of the ContainerTeamManaged objects that use the team.

Supported API: true

Parameters:
team -
Returns:
List
Throws:
WTException

setRoleDescription

void setRoleDescription(Role role,
                        String description,
                        ContainerTeam team)
                        throws WTException
The description to assign to the role.

Supported API: true

Parameters:
role -
description -
team -
Throws:
WTException

getRoleDescription

String getRoleDescription(Role role,
                          ContainerTeam team)
                          throws WTException


Supported API: true

Parameters:
role -
team -
Returns:
String
Throws:
WTException

updateContainerTeam

void updateContainerTeam(ContainerTeam team)
                         throws WTException


Supported API: true

Parameters:
team -
Throws:
WTException