|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.jackrabbit.core.ProtectedItemModifier org.apache.jackrabbit.core.security.user.UserManagerImpl
public class UserManagerImpl
UserManagerImpl
Field Summary | |
---|---|
static String |
AUTHORIZABLES_PATH
|
static String |
GROUP_ADMIN_GROUP_NAME
Configuration key and default value for the the name of the 'GroupAdmin' group-principal |
static String |
GROUPS_PATH
|
static NameFactory |
NF
|
static Name |
NT_REP_AUTHORIZABLE
|
static Name |
NT_REP_AUTHORIZABLE_FOLDER
|
static Name |
NT_REP_GROUP
|
static Name |
NT_REP_USER
|
static Name |
P_GROUPS
|
static Name |
P_IMPERSONATORS
Name of the user property containing the principal names of those allowed to impersonate. |
static Name |
P_PASSWORD
|
static Name |
P_PRINCIPAL_NAME
|
static Name |
P_REFEREES
|
static Name |
P_USERID
|
static String |
SECURITY_ROOT_PATH
root-path to security related content e.g. principals |
static String |
USER_ADMIN_GROUP_NAME
Configuration key and default value for the the name of the 'UserAdmin' group-principal. |
static String |
USERS_PATH
|
Fields inherited from interface org.apache.jackrabbit.api.security.user.UserManager |
---|
SEARCH_TYPE_AUTHORIZABLE, SEARCH_TYPE_GROUP, SEARCH_TYPE_USER |
Constructor Summary | |
---|---|
UserManagerImpl(SessionImpl session,
String adminId)
|
Method Summary | |
---|---|
Group |
createGroup(Principal principal)
Create a new Group with the given groupName . |
Group |
createGroup(Principal principal,
String intermediatePath)
Creates a new Group that is based on the given principal
and the specified itermediatePath hint. |
User |
createUser(String userID,
String password)
Creates a new Node on the repository with the specified userName . |
User |
createUser(String userID,
String password,
Principal principal,
String intermediatePath)
Creates an User for the given userID that authenitcates with the given Credentials and returns the specified
Principal upon Authorizable.getPrincipal() . |
Iterator |
findAuthorizables(String propertyName,
String value)
Returns all Authorizable s that have
property with the given name and
that Property equals the given value. |
Iterator |
findAuthorizables(String propertyName,
String value,
int searchType)
Returns all Authorizable s that have
property with the given name and
that Property equals the given value. |
Authorizable |
getAuthorizable(Principal principal)
Get the Authorizable by its main Principal. |
Authorizable |
getAuthorizable(String id)
Get the Authorizable by its id. |
void |
loggedOut(SessionImpl session)
Called when a Session has been 'closed' by
calling
|
void |
loggingOut(SessionImpl session)
Called when a Session is about to be 'closed' by
calling
|
Methods inherited from class org.apache.jackrabbit.core.ProtectedItemModifier |
---|
addNode, removeItem, setProperty, setProperty, setProperty |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final NameFactory NF
public static final String SECURITY_ROOT_PATH
public static final String AUTHORIZABLES_PATH
public static final String USERS_PATH
public static final String GROUPS_PATH
public static final String USER_ADMIN_GROUP_NAME
public static final String GROUP_ADMIN_GROUP_NAME
public static final Name P_REFEREES
public static final Name P_PRINCIPAL_NAME
public static final Name P_USERID
public static final Name P_PASSWORD
public static final Name P_GROUPS
public static final Name P_IMPERSONATORS
public static final Name NT_REP_AUTHORIZABLE
public static final Name NT_REP_AUTHORIZABLE_FOLDER
public static final Name NT_REP_USER
public static final Name NT_REP_GROUP
Constructor Detail |
---|
public UserManagerImpl(SessionImpl session, String adminId) throws RepositoryException
RepositoryException
Method Detail |
---|
public Authorizable getAuthorizable(String id) throws RepositoryException
UserManager
getAuthorizable
in interface UserManager
null
, if not present.
RepositoryException
UserManager.getAuthorizable(String)
public Authorizable getAuthorizable(Principal principal) throws RepositoryException
UserManager
getAuthorizable
in interface UserManager
null
, if not present.
RepositoryException
UserManager.getAuthorizable(Principal)
public Iterator findAuthorizables(String propertyName, String value) throws RepositoryException
UserManager
Authorizable
s that have
property
with the given name and
that Property equals the given value.
findAuthorizables
in interface UserManager
Authorizable
s that have a property with the given
name exactly matching the given value.
RepositoryException
UserManager.findAuthorizables(String,String)
public Iterator findAuthorizables(String propertyName, String value, int searchType) throws RepositoryException
UserManager
Authorizable
s that have
property
with the given name and
that Property equals the given value. In contrast to
UserManager.findAuthorizables(String, String)
the type of authorizable is
respected while executing the search.
findAuthorizables
in interface UserManager
searchType
- Any of the following constants:
RepositoryException
UserManager.findAuthorizables(String,String, int)
public User createUser(String userID, String password) throws RepositoryException
userName
.Credentials
are of type
SimpleCredentials
they will be
crypted.
createUser
in interface UserManager
userID
- password
-
User
.
AuthorizableExistsException
- in case the given userID is already
in use or another Authorizable with the same principal name exists.
RepositoryException
- If another error occurs.UserManager.createUser(String,String)
public User createUser(String userID, String password, Principal principal, String intermediatePath) throws AuthorizableExistsException, RepositoryException
UserManager
Credentials
and returns the specified
Principal upon Authorizable.getPrincipal()
. If the implementation is not
able to deal with the itermediatePath
that parameter should
be ignored.
Except for the itermediatePath
, neither of the specified
parameters can be null
.
createUser
in interface UserManager
userID
- password
- principal
- intermediatePath
-
AuthorizableExistsException
RepositoryException
public Group createGroup(Principal principal) throws RepositoryException
Group
with the given groupName
.
It will be created below the this UserManager's root Path.Nodes
of type rep:AuthorizableFolder
createGroup
in interface UserManager
principal
-
Group
.
AuthorizableExistsException
- in case the given groupID is already
in use or another Authorizable with the same principal name exists.
RepositoryException
- If another error occurs.UserManager.createGroup(Principal);
public Group createGroup(Principal principal, String intermediatePath) throws AuthorizableExistsException, RepositoryException
UserManager
Group
that is based on the given principal
and the specified itermediatePath
hint. If the implementation is not
able to deal with the itermediatePath
that parameter should
be ignored.
createGroup
in interface UserManager
principal
- intermediatePath
-
AuthorizableExistsException
RepositoryException
public void loggingOut(SessionImpl session)
SessionListener
Session
is about to be 'closed' by
calling Session.logout()
- Specified by:
loggingOut
in interface SessionListener
- Parameters:
session
- the Session
that is about to be 'closed'- See Also:
SessionListener.loggingOut(org.apache.jackrabbit.core.SessionImpl)
public void loggedOut(SessionImpl session)
SessionListener
Session
has been 'closed' by
calling Session.logout()
- Specified by:
loggedOut
in interface SessionListener
- Parameters:
session
- the Session
that has been 'closed'- See Also:
SessionListener.loggedOut(org.apache.jackrabbit.core.SessionImpl)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |