edu.internet2.middleware.grouper
Class GroupCopy

java.lang.Object
  extended by edu.internet2.middleware.grouper.GroupCopy

public class GroupCopy
extends Object

Use this class to copy a group to another stem.

Author:
shilen $Id: GroupCopy.java,v 1.3 2009-03-29 21:17:21 shilen Exp $

Constructor Summary
GroupCopy(Group group, Stem stem)
          Create a new instance of this class if you would like to specify specific options for a group copy.
 
Method Summary
 GroupCopy copyAttributes(boolean value)
          Whether to copy attributes.
 GroupCopy copyGroupAsPrivilege(boolean value)
          Whether to copy privileges where this group is a member.
 GroupCopy copyListGroupAsMember(boolean value)
          Whether to copy list memberships where this group is a member.
 GroupCopy copyListMembersOfGroup(boolean value)
          Whether to copy the list memberships of the group.
 GroupCopy copyPrivilegesOfGroup(boolean value)
          Whether to copy privileges of the group.
 Group save()
          Copy the group using the options set in this class.
 GroupCopy setDisplayExtension(String value)
          Optionally set a new display extension for the group.
 GroupCopy setExtension(String value)
          Optionally set a new extension for the group.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GroupCopy

public GroupCopy(Group group,
                 Stem stem)
Create a new instance of this class if you would like to specify specific options for a group copy. After setting the options, call save().

Parameters:
group - Group to copy
stem - Stem where group should be copied
Method Detail

copyPrivilegesOfGroup

public GroupCopy copyPrivilegesOfGroup(boolean value)
Whether to copy privileges of the group. Default is true.

Parameters:
value -
Returns:
GroupCopy

copyGroupAsPrivilege

public GroupCopy copyGroupAsPrivilege(boolean value)
Whether to copy privileges where this group is a member. Default is true.

Parameters:
value -
Returns:
GroupCopy

copyListMembersOfGroup

public GroupCopy copyListMembersOfGroup(boolean value)
Whether to copy the list memberships of the group. Default is true.

Parameters:
value -
Returns:
GroupCopy

copyListGroupAsMember

public GroupCopy copyListGroupAsMember(boolean value)
Whether to copy list memberships where this group is a member. Default is true.

Parameters:
value -
Returns:
GroupCopy

copyAttributes

public GroupCopy copyAttributes(boolean value)
Whether to copy attributes. Default is true.

Parameters:
value -
Returns:
GroupCopy

setExtension

public GroupCopy setExtension(String value)
Optionally set a new extension for the group.

Parameters:
value -
Returns:
GroupCopy

setDisplayExtension

public GroupCopy setDisplayExtension(String value)
Optionally set a new display extension for the group.

Parameters:
value -
Returns:
GroupCopy

save

public Group save()
           throws GroupAddException,
                  InsufficientPrivilegeException
Copy the group using the options set in this class.

Returns:
Group the new group
Throws:
GroupAddException
InsufficientPrivilegeException