Uses of Interface
org.keycloak.models.GroupModel
Packages that use GroupModel
Package
Description
-
Uses of GroupModel in org.keycloak.models
Fields in org.keycloak.models with type parameters of type GroupModelModifier and TypeFieldDescriptionstatic final SearchableModelField<GroupModel>GroupModel.SearchableFields.ASSIGNED_ROLEField for comparison with roles granted to this group.static final SearchableModelField<GroupModel>GroupModel.SearchableFields.ATTRIBUTESearch for attribute value.static final Comparator<GroupModel>GroupModel.COMPARE_BY_NAMEstatic final SearchableModelField<GroupModel>GroupModel.SearchableFields.IDstatic final SearchableModelField<GroupModel>GroupModel.SearchableFields.NAMEstatic final SearchableModelField<GroupModel>GroupModel.SearchableFields.PARENT_IDParent group IDstatic final SearchableModelField<GroupModel>GroupModel.SearchableFields.REALM_IDMethods in org.keycloak.models that return GroupModelModifier and TypeMethodDescriptiondefault GroupModelGroupProvider.createGroup(RealmModel realm, String name) Creates a new group with the given name in the given realm.default GroupModelGroupProvider.createGroup(RealmModel realm, String id, String name) Creates a new group with the given id and name in the given realm.GroupProvider.createGroup(RealmModel realm, String id, String name, GroupModel toParent) Creates a new group with the given name, id, name and parent to the given realm.default GroupModelGroupProvider.createGroup(RealmModel realm, String name, GroupModel toParent) Creates a new group with the given name and parent to the given realm.default GroupModelRealmModel.createGroup(String name) default GroupModelRealmModel.createGroup(String id, String name) RealmModel.createGroup(String id, String name, GroupModel toParent) default GroupModelRealmModel.createGroup(String name, GroupModel toParent) GroupModel.GroupRemovedEvent.getGroup()RealmModel.getGroupById(String id) GroupModel.getParent()Methods in org.keycloak.models that return types with arguments of type GroupModelModifier and TypeMethodDescriptionRealmModel.getDefaultGroupsStream()Returns default groups as a stream.GroupProvider.getGroupsByRoleStream(RealmModel realm, RoleModel role, Integer firstResult, Integer maxResults) Returns groups with the given role in the given realm.GroupProvider.getGroupsStream(RealmModel realm) Returns groups for the given realm.default Stream<GroupModel>GroupProvider.getGroupsStream(RealmModel realm, Stream<String> ids) Returns a stream of groups with given ids.default Stream<GroupModel>GroupProvider.getGroupsStream(RealmModel realm, Stream<String> ids, Integer first, Integer max) Returns a paginated stream of groups with given ids.GroupProvider.getGroupsStream(RealmModel realm, Stream<String> ids, String search, Integer first, Integer max) Returns a paginated stream of groups with given ids and given search value in group names.RealmModel.getGroupsStream()Returns groups as a stream.UserModel.getGroupsStream()Obtains the groups associated with the user.default Stream<GroupModel>UserModel.getGroupsStream(String search, Integer first, Integer max) Returns a paginated stream of groups within this realm with search in the nameGroupModel.getSubGroupsStream()Returns all sub groups for the parent group as a stream.GroupProvider.getTopLevelGroupsStream(RealmModel realm) Returns all top level groups (i.e.GroupProvider.getTopLevelGroupsStream(RealmModel realm, Integer firstResult, Integer maxResults) Returns top level groups (i.e.RealmModel.getTopLevelGroupsStream()Returns top level groups as a stream.RealmModel.getTopLevelGroupsStream(Integer first, Integer max) Returns top level groups as a stream.Methods in org.keycloak.models with parameters of type GroupModelModifier and TypeMethodDescriptionvoidGroupModel.addChild(GroupModel subGroup) Automatically calls setParent() on the subGroupvoidRealmModel.addDefaultGroup(GroupModel group) voidGroupProvider.addTopLevelGroup(RealmModel realm, GroupModel subGroup) Removes parent group for the given group in the given realm.GroupProvider.createGroup(RealmModel realm, String id, String name, GroupModel toParent) Creates a new group with the given name, id, name and parent to the given realm.default GroupModelGroupProvider.createGroup(RealmModel realm, String name, GroupModel toParent) Creates a new group with the given name and parent to the given realm.RealmModel.createGroup(String id, String name, GroupModel toParent) default GroupModelRealmModel.createGroup(String name, GroupModel toParent) booleanUserModel.isMemberOf(GroupModel group) voidUserModel.joinGroup(GroupModel group) voidUserModel.leaveGroup(GroupModel group) voidGroupProvider.moveGroup(RealmModel realm, GroupModel group, GroupModel toParent) This method is used for moving groups in group structure, for example: making an existing child group child group of some other group, setting a top level group (i.e.voidRealmModel.moveGroup(GroupModel group, GroupModel toParent) voidUserProvider.preRemove(RealmModel realm, GroupModel group) Called when a group is removed.voidGroupModel.removeChild(GroupModel subGroup) Automatically calls setParent() on the subGroupvoidRealmModel.removeDefaultGroup(GroupModel group) booleanGroupProvider.removeGroup(RealmModel realm, GroupModel group) Removes the given group for the given realm.booleanRealmModel.removeGroup(GroupModel group) voidGroupModel.setParent(GroupModel group) You must also call addChild on the parent group, addChild on RealmModel if there is no parent group -
Uses of GroupModel in org.keycloak.models.utils
Methods in org.keycloak.models.utils that return types with arguments of type GroupModelMethods in org.keycloak.models.utils with parameters of type GroupModelModifier and TypeMethodDescriptionstatic booleanRoleUtils.hasRoleFromGroup(GroupModel group, RoleModel targetRole, boolean checkParentGroup) Checks whether thetargetRoleis contained in the given group or its parents (if requested)static booleanRoleUtils.isDirectMember(Stream<GroupModel> groups, GroupModel targetGroup) static booleanRoleUtils.isMember(Stream<GroupModel> groups, GroupModel targetGroup) booleanUserModelDelegate.isMemberOf(GroupModel group) voidUserModelDelegate.joinGroup(GroupModel group) voidUserModelDelegate.leaveGroup(GroupModel group) Method parameters in org.keycloak.models.utils with type arguments of type GroupModelModifier and TypeMethodDescriptionstatic booleanRoleUtils.hasRoleFromGroup(Stream<GroupModel> groups, RoleModel targetRole, boolean checkParentGroup) Checks whether thetargetRoleis contained in any of thegroupsor their parents (if requested)static booleanRoleUtils.isDirectMember(Stream<GroupModel> groups, GroupModel targetGroup) static booleanRoleUtils.isMember(Stream<GroupModel> groups, GroupModel targetGroup) -
Uses of GroupModel in org.keycloak.storage.group
Methods in org.keycloak.storage.group that return GroupModelModifier and TypeMethodDescriptionGroupLookupProvider.getGroupById(RealmModel realm, String id) Returns a group from the given realm with the corresponding idMethods in org.keycloak.storage.group that return types with arguments of type GroupModelModifier and TypeMethodDescriptionGroupLookupProvider.searchForGroupByNameStream(RealmModel realm, String search, Boolean exact, Integer firstResult, Integer maxResults) Returns the group hierarchy with the given string in name for the given realm.default Stream<GroupModel>GroupLookupProvider.searchForGroupByNameStream(RealmModel realm, String search, Integer firstResult, Integer maxResults) Deprecated.GroupLookupProvider.searchGroupsByAttributes(RealmModel realm, Map<String, String> attributes, Integer firstResult, Integer maxResults) Returns the groups filtered by attribute names and attribute values for the given realm. -
Uses of GroupModel in org.keycloak.storage.user
Methods in org.keycloak.storage.user with parameters of type GroupModelModifier and TypeMethodDescriptionUserQueryMethodsProvider.getGroupMembersStream(RealmModel realm, GroupModel group) Obtains users that belong to a specific group.UserQueryMethodsProvider.getGroupMembersStream(RealmModel realm, GroupModel group, Integer firstResult, Integer maxResults) Obtains users that belong to a specific group.
GroupLookupProvider.searchForGroupByNameStream(RealmModel, String, Boolean, Integer, Integer)instead.