Interface DirectoryBackend
-
- All Known Subinterfaces:
NestedDirectoryBackend
- All Known Implementing Classes:
CachedDirectoryBackend,CachedWithPersistenceDirectoryBackend,CrowdDirectoryBackend,JsonDirectoryBackend,LockingDirectoryBackend,MirroredCrowdDirectoryBackend,ProxyDirectoryBackend
public interface DirectoryBackendThe interface for all directory backends.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Set<GroupEntity>getAllGroups()Gets all groups.Set<GroupEntity>getAllGroups(int startIndex, int maxResults)Gets all groups.Set<UserEntity>getAllUsers()Gets all users.Set<UserEntity>getAllUsers(int startIndex, int maxResults)Gets all users.UserEntitygetAuthenticatedUser(String id, String password)Gets info from authenticated user.Set<GroupEntity>getDirectChildGroupsOfGroup(String id)Gets direct child groups of group.Set<GroupEntity>getDirectGroupsOfUser(String id)Gets direct groups of user.Set<GroupEntity>getDirectParentGroupsOfGroup(String id)Gets direct parent groups of group.Set<UserEntity>getDirectUsersOfGroup(String id)Gets direct users of group.GroupEntitygetGroup(String id)Gets group info.StringgetId()Gets backend ID.Set<GroupEntity>getTransitiveChildGroupsOfGroup(String id)Gets transitive child groups of group.Set<GroupEntity>getTransitiveGroupsOfUser(String id)Gets transitive groups of user.Set<GroupEntity>getTransitiveParentGroupsOfGroup(String id)Gets transitive parent groups of group.Set<UserEntity>getTransitiveUsersOfGroup(String id)Gets transitive users of group.UserEntitygetUser(String id)Gets user info.MappableCursor<Row>runQueryExpression(String txId, org.apache.directory.api.ldap.model.schema.SchemaManager schemaManager, QueryExpression expression, EntityType entityType)Runs a query expression.voidshutdown()Shutdown method.voidstartup()Startup method.
-
-
-
Method Detail
-
getId
String getId()
Gets backend ID.- Returns:
- the backend ID
-
startup
void startup()
Startup method.
-
shutdown
void shutdown()
Shutdown method.
-
runQueryExpression
MappableCursor<Row> runQueryExpression(String txId, org.apache.directory.api.ldap.model.schema.SchemaManager schemaManager, QueryExpression expression, EntityType entityType)
Runs a query expression.- Parameters:
txId- the transaction IDschemaManager- the schema managerexpression- the query expressionentityType- the entity type- Returns:
- the query generator
-
getGroup
GroupEntity getGroup(String id) throws EntityNotFoundException
Gets group info.- Parameters:
id- the group ID- Returns:
- the group
- Throws:
EntityNotFoundException- the entry not found exception
-
getUser
UserEntity getUser(String id) throws EntityNotFoundException
Gets user info.- Parameters:
id- the user ID- Returns:
- the user
- Throws:
EntityNotFoundException- the entry not found exception
-
getAuthenticatedUser
UserEntity getAuthenticatedUser(String id, String password) throws EntityNotFoundException
Gets info from authenticated user.- Parameters:
id- the user IDpassword- the password- Returns:
- the authenticated user
- Throws:
EntityNotFoundException- the entry not found exception
-
getAllGroups
Set<GroupEntity> getAllGroups()
Gets all groups.- Returns:
- the groups
-
getAllGroups
Set<GroupEntity> getAllGroups(int startIndex, int maxResults)
Gets all groups.- Returns:
- the groups
-
getAllUsers
Set<UserEntity> getAllUsers()
Gets all users.- Returns:
- the users
-
getAllUsers
Set<UserEntity> getAllUsers(int startIndex, int maxResults)
Gets all users.- Returns:
- the users
-
getDirectUsersOfGroup
Set<UserEntity> getDirectUsersOfGroup(String id) throws EntityNotFoundException
Gets direct users of group.- Parameters:
id- the group ID- Returns:
- the direct users of group
- Throws:
EntityNotFoundException- the entry not found exception
-
getDirectGroupsOfUser
Set<GroupEntity> getDirectGroupsOfUser(String id) throws EntityNotFoundException
Gets direct groups of user.- Parameters:
id- the user ID- Returns:
- the direct groups of user
- Throws:
EntityNotFoundException- the entry not found exception
-
getTransitiveUsersOfGroup
Set<UserEntity> getTransitiveUsersOfGroup(String id) throws EntityNotFoundException
Gets transitive users of group.- Parameters:
id- the group ID- Returns:
- the transitive users of group
- Throws:
EntityNotFoundException- the entry not found exception
-
getTransitiveGroupsOfUser
Set<GroupEntity> getTransitiveGroupsOfUser(String id) throws EntityNotFoundException
Gets transitive groups of user.- Parameters:
id- the user ID- Returns:
- the transitive groups of user
- Throws:
EntityNotFoundException- the entry not found exception
-
getDirectChildGroupsOfGroup
Set<GroupEntity> getDirectChildGroupsOfGroup(String id) throws EntityNotFoundException
Gets direct child groups of group.- Parameters:
id- the group ID- Returns:
- the direct child groups of group
- Throws:
EntityNotFoundException- the entry not found exception
-
getDirectParentGroupsOfGroup
Set<GroupEntity> getDirectParentGroupsOfGroup(String id) throws EntityNotFoundException
Gets direct parent groups of group.- Parameters:
id- the group ID- Returns:
- the direct parent groups of group
- Throws:
EntityNotFoundException- the entry not found exception
-
getTransitiveChildGroupsOfGroup
Set<GroupEntity> getTransitiveChildGroupsOfGroup(String id) throws EntityNotFoundException
Gets transitive child groups of group.- Parameters:
id- the group ID- Returns:
- the transitive child groups of group
- Throws:
EntityNotFoundException- the entry not found exception
-
getTransitiveParentGroupsOfGroup
Set<GroupEntity> getTransitiveParentGroupsOfGroup(String id) throws EntityNotFoundException
Gets transitive parent groups of group.- Parameters:
id- the group ID- Returns:
- the transitive parent groups of group
- Throws:
EntityNotFoundException- the entry not found exception
-
-