org.apache.jackrabbit.api.security.user
Interface Group

All Superinterfaces:
Authorizable

public interface Group
extends Authorizable

A Group is a collection of Authorizables.


Method Summary
 boolean addMember(Authorizable authorizable)
          Add a member to this Group.
 Iterator<Authorizable> getDeclaredMembers()
           
 Iterator<Authorizable> getMembers()
           
 boolean isMember(Authorizable authorizable)
           
 boolean removeMember(Authorizable authorizable)
          Remove a member from this Group.
 
Methods inherited from interface org.apache.jackrabbit.api.security.user.Authorizable
declaredMemberOf, getID, getPrincipal, getProperty, getPropertyNames, hasProperty, isGroup, memberOf, remove, removeProperty, setProperty, setProperty
 

Method Detail

getDeclaredMembers

Iterator<Authorizable> getDeclaredMembers()
                                          throws RepositoryException
Returns:
Iterator of Authorizables which are declared members of this Group.
Throws:
RepositoryException - If an error occurs.

getMembers

Iterator<Authorizable> getMembers()
                                  throws RepositoryException
Returns:
Iterator of Authorizables which are members of this Group. This includes both declared members and all authorizables that are indirect group members.
Throws:
RepositoryException - If an error occurs.

isMember

boolean isMember(Authorizable authorizable)
                 throws RepositoryException
Parameters:
authorizable - The Authorizable to test.
Returns:
true if the Authorizable to test is a direct or indirect member of this Group.
Throws:
RepositoryException - If an error occurs.

addMember

boolean addMember(Authorizable authorizable)
                  throws RepositoryException
Add a member to this Group.

Parameters:
authorizable - The Authorizable to be added as member to this group.
Returns:
true if the Authorizable has successfully been added to this Group, false otherwise (e.g. unknown implemention or if it already is a member or if the passed authorizable is this group itself or for some implementation specific constraint).
Throws:
RepositoryException - If an error occurs.

removeMember

boolean removeMember(Authorizable authorizable)
                     throws RepositoryException
Remove a member from this Group.

Parameters:
authorizable - The Authorizable to be removed from the list of group members.
Returns:
true if the Authorizable was successfully removed. False otherwise.
Throws:
RepositoryException - If an error occurs.


Copyright © 2004-2010 The Apache Software Foundation. All Rights Reserved.