|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface RemoteDirectory
This interface is to be implemented when integrating various directory stores.
| Field Summary | |
|---|---|
static String |
DIRECTORY_TYPE
The name of the directory store. |
| Method Summary | |
|---|---|
RemoteGroup |
addGroup(RemoteGroup group)
Adds a group to the directory store. |
RemotePrincipal |
addPrincipal(RemotePrincipal principal)
Adds a principal to the directory store. |
void |
addPrincipalToGroup(String name,
String unsubscribedGroup)
Adds a principal to a group. |
void |
addPrincipalToRole(String name,
String unsubscribedRole)
Adds a principal to a role. |
RemoteRole |
addRole(RemoteRole role)
Adds a role to the directory store. |
RemotePrincipal |
authenticate(String name,
PasswordCredential[] credentials)
Authenticates a principal verses the directory store. |
RemoteGroup |
findGroupByName(String name)
Finds the group that matches the supplied name. |
List |
findGroupMemberships(String principal)
Returns a list of group names |
RemotePrincipal |
findPrincipalByName(String name)
Finds the principal that matches the supplied name. |
RemoteRole |
findRoleByName(String name)
Finds the role that matches the supplied name. |
List |
findRoleMemberships(String principalName)
Returns a list of role names |
Map |
getAttributes()
Gets the mapped values
of the directory store. |
String |
getDirectoryType()
Returns the DIRECTORY_TYPE name of the implementation. |
long |
getID()
Gets the internal unique ID of the directory store. |
boolean |
isGroupMember(String group,
String principal)
Checks if a principal is a member of a group. |
boolean |
isRoleMember(String role,
String principal)
Checks if a principal is a member of a role. |
void |
removeGroup(String name)
Removes the role that matches the supplied name. |
void |
removePrincipal(String name)
Removes the principal that matches the supplied name. |
void |
removePrincipalFromGroup(String name,
String unsubscribedGroup)
Removes a principal from a group. |
void |
removePrincipalFromRole(String name,
String removeRole)
Removes a principal from a role. |
void |
removeRole(String name)
Removes the group that matches the supplied name. |
List |
searchGroups(SearchContext searchContext)
Searches for all principals who match the supplied search criteria. |
List |
searchPrincipals(SearchContext searchContext)
Search for all principals who match the supplied search criteria. |
List |
searchRoles(SearchContext searchContext)
Search for all roles who match the supplied search criteria. |
void |
setAttributes(Map attributes)
When a directory store is loaded, the values will be
set by the crowd framework. |
void |
setID(long ID)
When a directory store is loaded, the ID will be set by the
crowd framework. |
void |
testConnection()
Test if a connection to the directory server can be established. |
RemoteGroup |
updateGroup(RemoteGroup group)
Updates the group by the name attribute. |
RemotePrincipal |
updatePrincipal(RemotePrincipal principal)
Updates the principal by the name attribute. |
void |
updatePrincipalCredential(String name,
PasswordCredential credential)
Updates the password credential for a principal. |
RemoteRole |
updateRole(RemoteRole role)
Updates the role by the name attribute. |
| Field Detail |
|---|
static final String DIRECTORY_TYPE
| Method Detail |
|---|
long getID()
ID of the directory store.
ID.void setID(long ID)
ID will be set by the
crowd framework.
ID - The ID.String getDirectoryType()
DIRECTORY_TYPE name of the implementation.
Map getAttributes()
values
of the directory store.
void setAttributes(Map attributes)
values will be
set by the crowd framework.
attributes - The values.
RemotePrincipal addPrincipal(RemotePrincipal principal)
throws InvalidPrincipalException,
RemoteException,
InvalidCredentialException
principal - The principal to add.
InvalidPrincipalException - The supplied principal is invalid.
RemoteException - An unknown remote exception occured.
InvalidCredentialException - The supplied credential(s) are invalid.
RemoteGroup addGroup(RemoteGroup group)
throws InvalidGroupException,
RemoteException
group - The group to add.
InvalidGroupException - The supplied group is invalid.
RemoteException - An unknown remote exception occured.
RemotePrincipal authenticate(String name,
PasswordCredential[] credentials)
throws RemoteException,
InvalidPrincipalException,
InactiveAccountException,
InvalidAuthenticationException
name - The name of the principal.credentials - The supplied credentials.
RemoteException - An unknown remote exception occured.
InvalidPrincipalException - The supplied principal is invalid.
InactiveAccountException - The supplied principal is inactive.
InvalidAuthenticationException - The supplied authentication is invalid.
boolean isGroupMember(String group,
String principal)
throws RemoteException
group - The group name.principal - The principal name.
true if and only if the principal is a member of the group, otherwise false.
RemoteException - An unknown remote exception occured.
List searchGroups(SearchContext searchContext)
throws RemoteException
principals who match the supplied search criteria.
searchContext - The search criteria.
results.
RemoteException - An unknown remote exception occured.
RemoteGroup findGroupByName(String name)
throws RemoteException,
ObjectNotFoundException
group that matches the supplied name.
name - The name of the group.
RemoteException - An unknown remote exception occured.
ObjectNotFoundException - The group does not exist.
RemoteGroup updateGroup(RemoteGroup group)
throws RemoteException,
ObjectNotFoundException
name attribute.
group - The group to update.
RemoteException - An unknown remote exception occured.
ObjectNotFoundException - the group does not exist.
List searchRoles(SearchContext searchContext)
throws RemoteException
roles who match the supplied search criteria.
searchContext - The search criteria.
results.
RemoteException - an unknown remote exception occured.
RemoteRole findRoleByName(String name)
throws RemoteException,
ObjectNotFoundException
role that matches the supplied name.
name - The name of the role.
RemoteException - An unknown remote exception occured.
ObjectNotFoundException - The role does not exist.
RemoteRole addRole(RemoteRole role)
throws InvalidRoleException,
RemoteException
role - The role to add.
InvalidRoleException - The supplied role is invalid.
RemoteException - An unknown remote exception occured.
RemoteRole updateRole(RemoteRole role)
throws RemoteException,
ObjectNotFoundException
name attribute.
role - The role to update.
RemoteException - An unknown remote exception occured.
ObjectNotFoundException - The role does not exist.
void removeGroup(String name)
throws RemoteException,
ObjectNotFoundException
role that matches the supplied name.
name - The name of the role.
RemoteException - An unknown remote exception occured.
ObjectNotFoundException - The role does not exist.
void removeRole(String name)
throws RemoteException,
ObjectNotFoundException
group that matches the supplied name.
name - The name of the group.
RemoteException - An unknown remote exception occured.
ObjectNotFoundException - The role does not exist.
List searchPrincipals(SearchContext searchContext)
throws RemoteException
principals who match the supplied search criteria.
searchContext - The search criteria.
results.
RemoteException - an unknown remote exception occured.
RemotePrincipal findPrincipalByName(String name)
throws RemoteException,
ObjectNotFoundException
principal that matches the supplied name.
name - The name of the principal.
RemoteException - An unknown remote exception occured.
ObjectNotFoundException - The principal does not exist.
RemotePrincipal updatePrincipal(RemotePrincipal principal)
throws RemoteException,
ObjectNotFoundException
name attribute.
principal - The principal to update.
RemoteException - An unknown remote exception occured.
ObjectNotFoundException - The role does not exist.
void addPrincipalToGroup(String name,
String unsubscribedGroup)
throws RemoteException
name - The name of the principal.unsubscribedGroup - The name of the group.
RemoteException - An unknown wire exception occured.
void removePrincipalFromGroup(String name,
String unsubscribedGroup)
throws RemoteException
name - The name of the principal.unsubscribedGroup - The name of the group.
RemoteException - An unknown wire exception occured.
void addPrincipalToRole(String name,
String unsubscribedRole)
throws RemoteException
name - The name of the principal.unsubscribedRole - The name of the role.
RemoteException - An unknown wire exception occured.
void removePrincipalFromRole(String name,
String removeRole)
throws RemoteException
name - The name of the principal.removeRole - The name of the role.
RemoteException - An unknown wire exception occured.
void removePrincipal(String name)
throws RemoteException,
ObjectNotFoundException
principal that matches the supplied name.
name - The name of the principal.
RemoteException - An unknown remote exception occured.
ObjectNotFoundException - The principal does not exist.
void updatePrincipalCredential(String name,
PasswordCredential credential)
throws RemoteException,
ObjectNotFoundException,
InvalidCredentialException
name - The name of the principal.credential - The new credential.
RemoteException - An unknown remote exception occured.
ObjectNotFoundException - The principal does not exist.
InvalidCredentialException - The supplied credential is invalid.
void testConnection()
throws RemoteException
RemoteException - An unknown wire exception occured.
boolean isRoleMember(String role,
String principal)
throws RemoteException
role - The group name.principal - The principal name.
true if and only if the principal is a member of the role, otherwise false.
RemoteException - An unknown remote exception occured.
List findGroupMemberships(String principal)
throws RemoteException,
ObjectNotFoundException
RemoteException - An unknown and remote exception occured.
ObjectNotFoundException
List findRoleMemberships(String principalName)
throws RemoteException,
ObjectNotFoundException
RemoteException - An unknown and remote exception occured.
ObjectNotFoundException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||