Class UserManagerWithComputedGroups
java.lang.Object
org.nuxeo.ecm.platform.usermanager.UserManagerImpl
org.nuxeo.ecm.platform.computedgroups.UserManagerWithComputedGroups
- All Implemented Interfaces:
Serializable
,AdministratorGroupsProvider
,MultiTenantUserManager
,UserManager
,Authenticator
,EventListener
- Direct Known Subclasses:
MultiTenantUserManager
UserManager
implementation that is aware of ComputedGroup
.- Author:
- Thierry Delprat
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.nuxeo.ecm.platform.usermanager.UserManager
UserManager.MatchType
-
Field Summary
Fields inherited from class org.nuxeo.ecm.platform.usermanager.UserManagerImpl
administratorGroups, administratorIds, ANCESTOR_GROUPS_PROPERTY_KEY, anonymousUser, cacheService, DEFAULT_ANONYMOUS_USER_ID, defaultGroup, digestAuthDirectory, digestAuthRealm, dirService, disableDefaultAdministratorsGroup, GROUPCHANGED_EVENT_ID, groupConfig, GROUPCREATED_EVENT_ID, GROUPDELETED_EVENT_ID, groupDirectoryName, groupIdField, groupLabelField, groupListingMode, groupMembersField, GROUPMODIFIED_EVENT_ID, groupParentGroupsField, groupSchemaName, groupSearchFields, groupSortField, groupSubGroupsField, ID_PROPERTY_KEY, INVALIDATE_ALL_PRINCIPALS_EVENT_ID, INVALIDATE_PRINCIPAL_EVENT_ID, multiTenantManagement, principalCache, SEARCH_ESCAPE_COMPAT_PARAM, USER_GROUP_CATEGORY, USER_HAS_PARTIAL_CONTENT, USERCHANGED_EVENT_ID, userConfig, USERCREATED_EVENT_ID, USERDELETED_EVENT_ID, userDirectoryName, userEmailField, userIdField, userListingMode, USERMANAGER_TOPIC, USERMODIFIED_EVENT_ID, userPasswordPattern, userSchemaName, userSearchFields, userSortField, VIRTUAL_FIELD_FILTER_PREFIX, virtualUsers
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected boolean
createGroup
(DocumentModel groupModel, DocumentModel context) Creates a group from given model with the given context.void
deleteGroup
(String groupId, DocumentModel context) Deletes group with given id with the given context.protected DocumentModel
getComputedGroupAsDocumentModel
(String grpName) Returns the nuxeo group with given name or null if it does not exist.getGroup
(String groupName, DocumentModel context) Returns the list of all groups ids.getGroupModel
(String groupName) Return the group document model with this id or null if group does not exist.protected ComputedGroupsService
protected NuxeoPrincipal
makePrincipal
(DocumentModel userEntry, boolean anonymous, List<String> groups) searchGroups
(Map<String, Serializable> filter, Set<String> fulltext) Returns groups matching given criteria.searchGroups
(Map<String, Serializable> filter, Set<String> fulltext, DocumentModel context) Returns groups matching given criteria with the given context. if the Document Context have a directory local configuration, the service try to open the user directory with directory suffix set into the local configurationsearchGroups
(QueryBuilder queryBuilder) Returns groups matching the given query.searchGroups
(QueryBuilder queryBuilder, DocumentModel context) Returns groups matching the given query, within the given context.void
updateGroup
(DocumentModel groupModel, DocumentModel context) Updates group represented by given model with the given context.Methods inherited from class org.nuxeo.ecm.platform.usermanager.UserManagerImpl
appendSubgroups, areGroupsReadOnly, areUsersReadOnly, authenticate, checkGrouId, checkGroupsExistence, checkPasswordValidity, checkUserId, checkUsernamePassword, cloneMap, cloneSet, createGroup, createUser, createUser, deleteGroup, deleteGroup, deleteGroup, deleteUser, deleteUser, deleteUser, deleteUser, encodeDigestAuthPassword, getAdministratorsGroups, getAncestorGroups, getAnonymousUserId, getBareGroupModel, getBareUserModel, getDefaultGroup, getDescendantGroups, getDigestAuthDirectory, getDigestAuthModel, getDigestAuthRealm, getDirectorySortMap, getGroupConfig, getGroupDirectoryName, getGroupId, getGroupIdField, getGroupIds, getGroupLabelField, getGroupListingMode, getGroupMembersField, getGroupModel, getGroupOrderBy, getGroupParentGroupsField, getGroupSchemaName, getGroupSearchFields, getGroupsInGroup, getGroupsInGroup, getGroupSortMap, getGroupSubGroupsField, getLeafPermissions, getPrincipal, getPrincipal, getPrincipal, getPrincipalUsingCache, getQueryForPattern, getTopLevelGroups, getTopLevelGroups, getUserDirectoryName, getUserEmailField, getUserId, getUserIdField, getUserIds, getUserIds, getUserListingMode, getUserModel, getUserModel, getUserModel, getUserOrderBy, getUserPasswordPattern, getUserSchemaName, getUserSearchFields, getUsersForPermission, getUsersForPermission, getUsersInGroup, getUsersInGroup, getUsersInGroupAndSubGroups, getUsersInGroupAndSubGroups, getUserSortField, getUserSortMap, handleEvent, invalidateAllPrincipals, invalidatePrincipal, isAnonymousMatching, isAnonymousMatching, makeAnonymousPrincipal, makeGroup, makePrincipal, makePrincipal, makeTransientPrincipal, makeVirtualPrincipal, makeVirtualUserEntry, notifyCore, notifyCore, notifyGroupChanged, notifyRuntime, notifyUserChanged, populateAncestorGroups, populateDescendantGroups, queryWithVirtualEntries, removeVirtualFilters, searchGroups, searchGroups, searchPrincipals, searchUsers, searchUsers, searchUsers, searchUsers, searchUsers, searchUsers, searchUsers, setConfiguration, setGroupDirectoryName, setUserDirectoryName, setVirtualUsers, syncDigestAuthPassword, updateGroup, updateUser, updateUser, useCache, useSearchEscapeCompat, validatePassword
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.nuxeo.ecm.platform.usermanager.UserManager
getPrincipal, notifyGroupChanged
-
Field Details
-
useComputedGroup
-
VIRTUAL_GROUP_MARKER
- See Also:
-
-
Constructor Details
-
UserManagerWithComputedGroups
public UserManagerWithComputedGroups()
-
-
Method Details
-
getService
-
activateComputedGroup
protected boolean activateComputedGroup() -
makePrincipal
protected NuxeoPrincipal makePrincipal(DocumentModel userEntry, boolean anonymous, List<String> groups) - Overrides:
makePrincipal
in classUserManagerImpl
-
getGroup
Description copied from interface:UserManager
Returns the nuxeo group with given name or null if it does not exist.- Specified by:
getGroup
in interfaceUserManager
- Overrides:
getGroup
in classUserManagerImpl
-
getGroup
- Overrides:
getGroup
in classUserManagerImpl
-
getGroupIds
Description copied from interface:UserManager
Returns the list of all groups ids.- Specified by:
getGroupIds
in interfaceUserManager
- Overrides:
getGroupIds
in classUserManagerImpl
-
getGroupModel
Description copied from interface:UserManager
Return the group document model with this id or null if group does not exist.- Specified by:
getGroupModel
in interfaceUserManager
- Overrides:
getGroupModel
in classUserManagerImpl
- Parameters:
groupName
- the group identifier
-
searchGroups
Description copied from interface:UserManager
Returns groups matching given criteria.- Specified by:
searchGroups
in interfaceUserManager
- Overrides:
searchGroups
in classUserManagerImpl
- Parameters:
filter
- filter with field names as keysfulltext
- field names used for fulltext match
-
searchGroups
public DocumentModelList searchGroups(Map<String, Serializable> filter, Set<String> fulltext, DocumentModel context) Description copied from interface:MultiTenantUserManager
Returns groups matching given criteria with the given context. if the Document Context have a directory local configuration, the service try to open the user directory with directory suffix set into the local configuration- Specified by:
searchGroups
in interfaceMultiTenantUserManager
- Overrides:
searchGroups
in classUserManagerImpl
- Parameters:
filter
- filter with field names as keysfulltext
- field names used for fulltext match
-
searchGroups
Description copied from interface:UserManager
Returns groups matching the given query.- Specified by:
searchGroups
in interfaceUserManager
- Overrides:
searchGroups
in classUserManagerImpl
- Parameters:
queryBuilder
- the query to use, including limit, offset, ordering and countTotal
-
searchGroups
Description copied from interface:MultiTenantUserManager
Returns groups matching the given query, within the given context.- Specified by:
searchGroups
in interfaceMultiTenantUserManager
- Overrides:
searchGroups
in classUserManagerImpl
- Parameters:
queryBuilder
- the query to use, including limit, offset, ordering and countTotalcontext
- the context for the tenant, ornull
-
getComputedGroupAsDocumentModel
-
createGroup
Description copied from interface:MultiTenantUserManager
Creates a group from given model with the given context. If the Document Context have a directory local configuration, the service will append at the end of the groupname the directory suffix set into the local configuration of the context document.- Specified by:
createGroup
in interfaceMultiTenantUserManager
- Overrides:
createGroup
in classUserManagerImpl
- Returns:
- the created group model
-
updateGroup
Description copied from interface:MultiTenantUserManager
Updates group represented by given model with the given context. If the Document Context have a directory local configuration, the service will append at the end of the groupname the directory suffix set into the local configuration of the context document.- Specified by:
updateGroup
in interfaceMultiTenantUserManager
- Overrides:
updateGroup
in classUserManagerImpl
-
deleteGroup
Description copied from interface:MultiTenantUserManager
Deletes group with given id with the given context. If the Document Context have a directory local configuration, the service will append at the end of the groupname the directory suffix set into the local configuration of the context document.- Specified by:
deleteGroup
in interfaceMultiTenantUserManager
- Overrides:
deleteGroup
in classUserManagerImpl
-