|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.internet2.middleware.grouper.GroupFinder
public class GroupFinder
Find groups within the Groups Registry.
Constructor Summary | |
---|---|
GroupFinder()
default constructor |
Method Summary | |
---|---|
GroupFinder |
addGroupId(java.lang.String groupId)
add a group id to search for |
GroupFinder |
addGroupName(java.lang.String groupName)
add a group name to search for |
GroupFinder |
addPrivilege(Privilege privilege)
add a privilege to filter by that the subject has on the group |
GroupFinder |
addTypeOfGroup(TypeOfGroup typeOfGroup)
|
GroupFinder |
assignAttributeValue(java.lang.Object theValue)
find objects with this value |
GroupFinder |
assignCompositeOwner(java.lang.Boolean theCompositeOwner)
if we are filtering for groups which are composite owners or not |
GroupFinder |
assignField(Field theField)
field to look for if searching for memberships in groups |
GroupFinder |
assignFieldName(java.lang.String theFieldName)
field name to look for if searching for memberships in groups |
GroupFinder |
assignFindByUuidOrName(boolean theFindByUuidOrName)
if we are looking up a group, only look by uuid or name |
GroupFinder |
assignGroupIds(java.util.Collection<java.lang.String> theGroupIds)
assign group ids to search for |
GroupFinder |
assignGroupNames(java.util.Collection<java.lang.String> theGroupNames)
assign group names to search for |
GroupFinder |
assignIdOfAttributeDefName(java.lang.String theAttributeDefNameId)
find groups that have this attribute assigned |
GroupFinder |
assignMembershipsForSubject(boolean membershipsForSubject1)
if this is true, or there is a field assigned, then get memberships for a subject |
GroupFinder |
assignNameOfAttributeDefName(java.lang.String theNameOfAttributeDefName)
find groups that have this attribute assigned |
GroupFinder |
assignParentStemId(java.lang.String theParentStemId)
parent or ancestor stem of the group |
GroupFinder |
assignPrivileges(java.util.Set<Privilege> theGroups)
assign privileges to filter by that the subject has on the group |
GroupFinder |
assignQueryOptions(QueryOptions theQueryOptions)
if sorting, paging, caching, etc |
GroupFinder |
assignScope(java.lang.String theScope)
scope to look for groups Wildcards will be appended or percent is the wildcard |
GroupFinder |
assignSplitScope(boolean theSplitScope)
if the scope has spaces in it, then split by whitespace, and find results that contain all of the scope strings |
GroupFinder |
assignStemScope(Stem.Scope theStemScope)
if passing in a stem, this is the stem scope... |
GroupFinder |
assignSubject(edu.internet2.middleware.subject.Subject theSubject)
this is the subject that has certain memberships in the query |
GroupFinder |
assignSubjectNotInGroup(edu.internet2.middleware.subject.Subject theSubjectNotInGroup)
assign a subject which does not have a membership in the group |
GroupFinder |
assignTypeOfGroups(java.util.Set<TypeOfGroup> theTypeOfGroups)
|
static java.util.Set<Group> |
findAllByAttribute(GrouperSession s,
java.lang.String attr,
java.lang.String val)
Find Groups by attribute value. |
static java.util.Set<Group> |
findAllByType(GrouperSession s,
GroupType type)
Find all groups within the registry by their GroupType . |
static Group |
findByAlternateName(GrouperSession s,
java.lang.String name,
boolean exceptionIfNotFound)
Find a group within the registry by its alternate name. |
static Group |
findByAttribute(GrouperSession s,
java.lang.String attr,
java.lang.String val)
Deprecated. use the overload |
static Group |
findByAttribute(GrouperSession s,
java.lang.String attr,
java.lang.String val,
boolean exceptionOnNull)
Find Group by attribute value. |
static Group |
findByCurrentName(GrouperSession s,
java.lang.String name,
boolean exceptionIfNotFound)
Find a group within the registry by its current name. |
static Group |
findByIdIndexSecure(java.lang.Long idIndex,
boolean exceptionIfNotFound,
QueryOptions queryOptions)
Find a group within the registry by ID index. |
static Group |
findByName(GrouperSession s,
java.lang.String name)
Deprecated. |
static Group |
findByName(GrouperSession s,
java.lang.String name,
boolean exceptionIfNotFound)
Find a group within the registry by name. |
static Group |
findByName(GrouperSession s,
java.lang.String name,
boolean exceptionIfNotFound,
QueryOptions queryOptions)
Find a group within the registry by name. |
static Group |
findByUuid(GrouperSession s,
java.lang.String uuid)
Deprecated. |
static Group |
findByUuid(GrouperSession s,
java.lang.String uuid,
boolean exceptionIfNotFound)
Find a group within the registry by UUID. |
static Group |
findByUuid(GrouperSession s,
java.lang.String uuid,
boolean exceptionIfNotFound,
QueryOptions queryOptions)
Find a group within the registry by UUID. |
Group |
findGroup()
find the group |
java.util.Set<Group> |
findGroups()
find all the group |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public GroupFinder()
Method Detail |
---|
public GroupFinder assignCompositeOwner(java.lang.Boolean theCompositeOwner)
theCompositeOwner
-
@Deprecated public static Group findByAttribute(GrouperSession s, java.lang.String attr, java.lang.String val) throws GroupNotFoundException, java.lang.IllegalArgumentException
try { Group g = GroupFinder.findByAttribute(s, "description", "some value"); } catch (GroupNotFoundException eGNF) { }
s
- Search within this session context.attr
- Search on this attribute.val
- Search for this value.
Group
.
GroupNotFoundException
java.lang.IllegalArgumentException
public static Group findByAttribute(GrouperSession s, java.lang.String attr, java.lang.String val, boolean exceptionOnNull) throws GroupNotFoundException, java.lang.IllegalArgumentException
Group g = GroupFinder.findByAttribute(s, "description", "some value", true);
s
- Search within this session context.attr
- Search on this attribute.val
- Search for this value.exceptionOnNull
- true if there should be an exception on null
Group
.
GroupNotFoundException
java.lang.IllegalArgumentException
public static java.util.Set<Group> findAllByAttribute(GrouperSession s, java.lang.String attr, java.lang.String val) throws java.lang.IllegalArgumentException
Setgroups = GroupFinder.findAllByAttribute(s, "description", "some value");
s
- Search within this session context.attr
- Search on this attribute.val
- Search for this value.
Group
.
java.lang.IllegalArgumentException
@Deprecated public static Group findByName(GrouperSession s, java.lang.String name) throws GroupNotFoundException
try { Group g = GroupFinder.findByName(name); } catch (GroupNotFoundException e) { // Group not found }
s
- Find group within this session context.name
- Name of group to find.
Group
GroupNotFoundException
public static Group findByName(GrouperSession s, java.lang.String name, boolean exceptionIfNotFound) throws GroupNotFoundException
try { Group g = GroupFinder.findByName(name); } catch (GroupNotFoundException e) { // Group not found }
s
- Find group within this session context.name
- Name of group to find.exceptionIfNotFound
-
Group
GroupNotFoundException
public static Group findByName(GrouperSession s, java.lang.String name, boolean exceptionIfNotFound, QueryOptions queryOptions) throws GroupNotFoundException
try { Group g = GroupFinder.findByName(name); } catch (GroupNotFoundException e) { // Group not found }
s
- Find group within this session context.name
- Name of group to find.exceptionIfNotFound
- queryOptions
- paging, sorting, caching options
Group
GroupNotFoundException
public static Group findByCurrentName(GrouperSession s, java.lang.String name, boolean exceptionIfNotFound) throws GroupNotFoundException
try { Group g = GroupFinder.findByCurrentName(name, true); } catch (GroupNotFoundException e) { // Group not found }
s
- Find group within this session context.name
- Name of group to find.exceptionIfNotFound
-
Group
GroupNotFoundException
public static Group findByAlternateName(GrouperSession s, java.lang.String name, boolean exceptionIfNotFound) throws GroupNotFoundException
try { Group g = GroupFinder.findByAlternateName(name, true); } catch (GroupNotFoundException e) { // Group not found }
s
- Find group within this session context.name
- Name of group to find.exceptionIfNotFound
-
Group
GroupNotFoundException
public static java.util.Set<Group> findAllByType(GrouperSession s, GroupType type) throws java.lang.IllegalArgumentException
GroupType
. Or empty set if none (never null).
Setgroups = GroupFinder.findAllByType( s, GroupTypeFinder.find("your type") );
s
- Find group within this session context.type
- Find group with this GroupType
.
Group
s
java.lang.IllegalArgumentException
@Deprecated public static Group findByUuid(GrouperSession s, java.lang.String uuid) throws GroupNotFoundException
Group g = GroupFinder.findByUuid(s, uuid);
s
- Find group within this session context.uuid
- UUID of group to find.
Group
GroupNotFoundException
public static Group findByUuid(GrouperSession s, java.lang.String uuid, boolean exceptionIfNotFound) throws GroupNotFoundException
Group g = GroupFinder.findByUuid(s, uuid);
s
- Find group within this session context.uuid
- UUID of group to find.exceptionIfNotFound
- true if exception if not found
Group
GroupNotFoundException
- if not found an exceptionIfNotFound is truepublic static Group findByUuid(GrouperSession s, java.lang.String uuid, boolean exceptionIfNotFound, QueryOptions queryOptions) throws GroupNotFoundException
Group g = GroupFinder.findByUuid(s, uuid);
s
- Find group within this session context.uuid
- UUID of group to find.exceptionIfNotFound
- true if exception if not foundqueryOptions
-
Group
GroupNotFoundException
- if not found an exceptionIfNotFound is truepublic static Group findByIdIndexSecure(java.lang.Long idIndex, boolean exceptionIfNotFound, QueryOptions queryOptions) throws GroupNotFoundException
idIndex
- id index of group to find.exceptionIfNotFound
- true if exception if not foundqueryOptions
-
Group
GroupNotFoundException
- if not found an exceptionIfNotFound is truepublic GroupFinder assignSubjectNotInGroup(edu.internet2.middleware.subject.Subject theSubjectNotInGroup)
theSubjectNotInGroup
-
public GroupFinder addPrivilege(Privilege privilege)
privilege
- should be AccessPrivilege
public GroupFinder assignPrivileges(java.util.Set<Privilege> theGroups)
theGroups
-
public GroupFinder assignQueryOptions(QueryOptions theQueryOptions)
theQueryOptions
-
public GroupFinder assignAttributeValue(java.lang.Object theValue)
theValue
-
public GroupFinder assignIdOfAttributeDefName(java.lang.String theAttributeDefNameId)
theAttributeDefNameId
-
public GroupFinder assignNameOfAttributeDefName(java.lang.String theNameOfAttributeDefName)
theNameOfAttributeDefName
-
public GroupFinder addGroupId(java.lang.String groupId)
groupId
-
public GroupFinder assignGroupNames(java.util.Collection<java.lang.String> theGroupNames)
theGroupNames
-
public GroupFinder addGroupName(java.lang.String groupName)
groupName
-
public GroupFinder assignGroupIds(java.util.Collection<java.lang.String> theGroupIds)
theGroupIds
-
public GroupFinder assignField(Field theField)
theField
-
public GroupFinder assignFieldName(java.lang.String theFieldName)
theFieldName
-
public GroupFinder assignMembershipsForSubject(boolean membershipsForSubject1)
membershipsForSubject1
-
public java.util.Set<Group> findGroups()
public GroupFinder assignTypeOfGroups(java.util.Set<TypeOfGroup> theTypeOfGroups)
theTypeOfGroups
-
public GroupFinder addTypeOfGroup(TypeOfGroup typeOfGroup)
typeOfGroup
-
public GroupFinder assignScope(java.lang.String theScope)
theScope
-
public GroupFinder assignSplitScope(boolean theSplitScope)
theSplitScope
-
public GroupFinder assignSubject(edu.internet2.middleware.subject.Subject theSubject)
theSubject
-
public GroupFinder assignParentStemId(java.lang.String theParentStemId)
theParentStemId
-
public GroupFinder assignStemScope(Stem.Scope theStemScope)
theStemScope
-
public GroupFinder assignFindByUuidOrName(boolean theFindByUuidOrName)
theFindByUuidOrName
-
public Group findGroup()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |