org.restlet.security
Class Group

java.lang.Object
  extended by org.restlet.security.Group

public class Group
extends Object

Group that contains member groups and users.

Author:
Jerome Louvel

Constructor Summary
Group()
          Default constructor.
Group(String name, String description)
          Constructor.
Group(String name, String description, boolean inheritingRoles)
          Constructor.
 
Method Summary
 String getDescription()
          Returns the description.
 List<Group> getMemberGroups()
          Returns the modifiable list of member groups.
 List<User> getMemberUsers()
           
 String getName()
          Returns the display name.
 boolean isInheritingRoles()
          Indicates if the roles of the parent group should be inherited.
 void setDescription(String description)
          Sets the description.
 void setInheritingRoles(boolean inheritingRoles)
          Indicates if the roles of the parent group should be inherited.
 void setMemberGroups(List<Group> memberGroups)
          Sets the modifiable list of member groups.
 void setMemberUsers(List<User> memberUsers)
          Sets the modifiable list of member user references.
 void setName(String name)
          Sets the display name.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Group

public Group()
Default constructor. Note that roles are inherited by default.


Group

public Group(String name,
             String description)
Constructor. Note that roles are inherited by default.

Parameters:
name - The display name.
description - The description.

Group

public Group(String name,
             String description,
             boolean inheritingRoles)
Constructor.

Parameters:
name - The display name.
description - The description.
inheritingRoles - Indicates if the roles of the parent group should be inherited.
Method Detail

getDescription

public String getDescription()
Returns the description.

Returns:
The description

getMemberGroups

public List<Group> getMemberGroups()
Returns the modifiable list of member groups.

Returns:
The modifiable list of member groups.

getMemberUsers

public List<User> getMemberUsers()

getName

public String getName()
Returns the display name.

Returns:
The display name.

isInheritingRoles

public boolean isInheritingRoles()
Indicates if the roles of the parent group should be inherited. Those roles indirectly cover the granted or denied permissions.

Returns:
True if the roles of the parent group should be inherited.

setDescription

public void setDescription(String description)
Sets the description.

Parameters:
description - The description.

setInheritingRoles

public void setInheritingRoles(boolean inheritingRoles)
Indicates if the roles of the parent group should be inherited. Those roles indirectly cover the granted or denied permissions.

Parameters:
inheritingRoles - True if the roles of the parent group should be inherited.

setMemberGroups

public void setMemberGroups(List<Group> memberGroups)
Sets the modifiable list of member groups. This method clears the current list and adds all entries in the parameter list.

Parameters:
memberGroups - A list of member groups.

setMemberUsers

public void setMemberUsers(List<User> memberUsers)
Sets the modifiable list of member user references. This method clears the current list and adds all entries in the parameter list.

Parameters:
memberUsers - A list of member user references.

setName

public void setName(String name)
Sets the display name.

Parameters:
name - The display name.

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2005-2013 Restlet.