|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.turbine.util.security.SecuritySet<Group>
org.apache.turbine.util.security.GroupSet
public class GroupSet
This class represents a set of Groups. It's useful for building administration UI. It enforces that only Group objects are allowed in the set and only relevant methods are available.
| Field Summary |
|---|
| Fields inherited from class org.apache.turbine.util.security.SecuritySet |
|---|
idMap, nameMap |
| Constructor Summary | |
|---|---|
GroupSet()
Constructs an empty GroupSet |
|
GroupSet(Collection<Group> groups)
Constructs a new GroupSet with specified contents. |
|
| Method Summary | |
|---|---|
boolean |
add(Collection<Group> groups)
Adds the Groups in a Collection to this GroupSet. |
boolean |
add(Group group)
Adds a Group to this GroupSet. |
boolean |
add(GroupSet groupSet)
Adds the Groups in another GroupSet to this GroupSet. |
boolean |
contains(Group group)
Checks whether this GroupSet contains a Group. |
Group |
getGroupById(int groupId)
Returns a Group with the given id, if it is contained in this GroupSet. |
Group |
getGroupByName(String groupName)
Returns a Group with the given name, if it is contained in this GroupSet. |
Group[] |
getGroupsArray()
Returns an Array of Groups in this GroupSet. |
boolean |
remove(Group group)
Removes a Group from this GroupSet. |
String |
toString()
Print out a GroupSet as a String |
| Methods inherited from class org.apache.turbine.util.security.SecuritySet |
|---|
clear, containsId, containsName, getIds, getNames, getSet, iterator, size |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public GroupSet()
public GroupSet(Collection<Group> groups)
groups - A collection of groups to be contained in the set.| Method Detail |
|---|
public boolean add(Group group)
group - A Group.
public boolean add(Collection<Group> groups)
groups - A Collection of Groups.
public boolean add(GroupSet groupSet)
groupSet - A GroupSet.
public boolean remove(Group group)
group - A Group.
public boolean contains(Group group)
group - A Group.
public Group getGroupByName(String groupName)
groupName - Name of Group.
public Group getGroupById(int groupId)
groupId - Id of the group
public Group[] getGroupsArray()
public String toString()
toString in class SecuritySet<Group>
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||