Package org.nuxeo.ecm.platform.login
Class GroupImpl
- java.lang.Object
-
- org.nuxeo.ecm.platform.login.GroupImpl
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
addMember(Principal user)
adds the specified member to the group.boolean
equals(Object obj)
This function returns true if the group passed matches the group represented in this interface.boolean
equals(Group other)
String
getName()
return the name of the principal.int
hashCode()
return a hashcode for the principal.boolean
isMember(Principal member)
returns true if the passed principal is a member of the group.Enumeration<? extends Principal>
members()
returns the enumeration of the members in the group.boolean
removeMember(Principal user)
Removes the specified member from the group.String
toString()
Prints a stringified version of the group.
-
-
-
Constructor Detail
-
GroupImpl
public GroupImpl(String groupName)
Constructs a Group object with no members.- Parameters:
groupName
- the name of the group
-
-
Method Detail
-
addMember
public boolean addMember(Principal user)
adds the specified member to the group.
-
removeMember
public boolean removeMember(Principal user)
Removes the specified member from the group.- Specified by:
removeMember
in interfaceGroup
- Parameters:
user
- The principal to remove from the group.- Returns:
- true if the principal was removed false if the principal was not a member
-
members
public Enumeration<? extends Principal> members()
returns the enumeration of the members in the group.
-
equals
public boolean equals(Object obj)
This function returns true if the group passed matches the group represented in this interface.
-
equals
public boolean equals(Group other)
-
toString
public String toString()
Prints a stringified version of the group.
-
hashCode
public int hashCode()
return a hashcode for the principal.
-
isMember
public boolean isMember(Principal member)
returns true if the passed principal is a member of the group.
-
-