Home » apache-tomcat-6.0.26-src » org.apache » tomcat » security » file » [javadoc | source]
final class: FileRealmGroup [javadoc | source]
In-memory representation of a defined group of users, which may be granted specific roles indirectly by virtue of their membership in a group. This class exhibits the following JavaBeans properties:
 FileRealmGroup(FileRealmDatabase database,
    String name) 
    [Package Private] Create a new group with the specified group name. It is assumed that the creating entity has ensured that this group name is unique within this security realm.
    database - The FileRealmDatabase containing the new group
    name - The group name assigned to the new group
Method from org.apache.tomcat.security.file.FileRealmGroup Summary:
addRole,   addUser,   destroy,   getName,   getRoles,   getUsers,   hasRole,   remove,   remove
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.apache.tomcat.security.file.FileRealmGroup Detail:
 public  void addRole(String role) 
    Add the explicit assignment of the specified role to this group.
  void addUser(FileRealmUser user) 
    [Package Private] Add the specified user to the group members of this group.
 public  void destroy() 
    Remove this group from the database to which it belongs.
 public String getName() 
    Return the group name of this group.
 public Enumeration getRoles() 
    Return an enumeration of the roles explicitly assigned to this group. If there are no assigned roles, an empty enumeration is returned.
 public Enumeration getUsers() 
    Return an enumeration of the users who are members of this group. Each element is an instance of FileRealmUser.
 public boolean hasRole(String role) 
    Has this user been assigned the specified role, either directly or indirectly by virtue of group membership?
 public  void remove(String role) 
    Remove the specified explicitly assigned role from this group.
  void remove(FileRealmUser user) 
    [Package Private] Remove the specified user from membership in this group.