Oracle Fusion Middleware Java API Reference for Oracle ADF Share
11g Release 2 (11.1.2.0.0)

E17486-01

oracle.adf.share.security.identitymanagement
Class UserManager

java.lang.Object
  extended by oracle.adf.share.security.identitymanagement.UserManager

public class UserManager
extends java.lang.Object

Retrieve, create, update and delete user in identity store.


Constructor Summary
UserManager()
          Constructor of the UserManager class.
UserManager(java.util.Hashtable env)
          Internal: Applications should not use this method. Constructor for UserManager that takes in a provider class name.
UserManager(java.lang.String providerClassName)
          Internal: Applications should not use this method. Constructor for UserManager that takes in a provider class name.
 
Method Summary
 java.security.Principal addUser(User user, Credential cred)
          Create a user in identity store with the specified User and Credential.
 User createUser()
          Creates a User object.
 void deleteUser(java.security.Principal principal)
          Delete from identity store the specified Principal.
 java.security.Principal getAnonymousUser()
          Returns ther anonymous user principal.
 java.lang.String getAnonymousUserName()
          Returns the name of anonymous user.
 java.security.Principal getPrincipal(java.lang.String username)
          Retrieve the Principal from identity store of the specified username.
 User getUser(java.security.Principal principal)
          Returns the User of the specified principal.
 java.util.ArrayList getUserList(int sizeLimit, AttributeFilter[] filter)
          Returns a list of users for the specified filter and size limit.
 java.util.ArrayList getUserList(int sizeLimit, AttributeFilter[] filter, java.security.Principal role)
          Returns a list of user grantee of specified role principal, and user attribute filter and size limit.
 java.util.ArrayList getUserProfileList(int sizeLimit, AttributeFilter[] filter)
          Returns a list of UserProfile for the specified filter and size limit.
 java.lang.Object getUserProfilePropertyVal(java.lang.String name, java.lang.String propName)
          Returns the UserProfile property value for the specified user name and property name.
 boolean isAddUserSupported()
          Returns true if addUser to identity store is supported.
 boolean isDeleteUserSupported()
          Returns true if deleteUser from identity store is supported.
 boolean isModifyUserSupported()
          Returns true if modifiyUser in identity store is supported.
 void modifyUser(java.security.Principal principal, User user)
          Internal: Applications should not use this method. Method not implemented by this class.
 void saveUserProfile(java.lang.String userName, java.util.HashMap values)
          Saves user profile values for the specified user.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UserManager

public UserManager()
Constructor of the UserManager class.

This constructor reads the test.properties file for the providerClass property, which should be a class name of a class that implements the IdentityManagement interface.

The class that is specified is then set up as the IdentityManagement provider for this API.


UserManager

public UserManager(java.lang.String providerClassName)
Internal: Applications should not use this method. Constructor for UserManager that takes in a provider class name.

Parameters:
providerClassName - identity management provider class name.

UserManager

public UserManager(java.util.Hashtable env)
Internal: Applications should not use this method. Constructor for UserManager that takes in a provider class name.

Parameters:
properties - initialization property values.
Method Detail

addUser

public java.security.Principal addUser(User user,
                                       Credential cred)
Create a user in identity store with the specified User and Credential.

Parameters:
user - the user to be added
cred - the user credentials
Returns:
Principal user principal.

createUser

public User createUser()
Creates a User object.


getPrincipal

public java.security.Principal getPrincipal(java.lang.String username)
Retrieve the Principal from identity store of the specified username.

Parameters:
username - the user name
Returns:
Principal user principal

getUser

public User getUser(java.security.Principal principal)
Returns the User of the specified principal.

Parameters:
principal - the user principal
Returns:
User an instance of user for the principal.

modifyUser

public void modifyUser(java.security.Principal principal,
                       User user)
Internal: Applications should not use this method. Method not implemented by this class.

Parameters:
principal - the principal.
user - the user object.

deleteUser

public void deleteUser(java.security.Principal principal)
Delete from identity store the specified Principal.

Parameters:
principal - the principal of the user to be removed.

isAddUserSupported

public boolean isAddUserSupported()
Returns true if addUser to identity store is supported.

Returns:
boolean true if add user is supported.

isModifyUserSupported

public boolean isModifyUserSupported()
Returns true if modifiyUser in identity store is supported.

Returns:
boolean true is modify user is supported.

isDeleteUserSupported

public boolean isDeleteUserSupported()
Returns true if deleteUser from identity store is supported.

Returns:
boolean true if delete user is supported.

getUserList

public java.util.ArrayList getUserList(int sizeLimit,
                                       AttributeFilter[] filter)
Returns a list of users for the specified filter and size limit.

Parameters:
sizeLimit - the maximum return size.
filter - filter attributes
Returns:
ArrayList the list of users for given role grant.

getUserList

public java.util.ArrayList getUserList(int sizeLimit,
                                       AttributeFilter[] filter,
                                       java.security.Principal role)
Returns a list of user grantee of specified role principal, and user attribute filter and size limit.

Parameters:
sizeLimit - the maximum return size.
filter - filter attributes
role - role grant
Returns:
ArrayList the list of users for given role grant.

getUserProfileList

public java.util.ArrayList getUserProfileList(int sizeLimit,
                                              AttributeFilter[] filter)
Returns a list of UserProfile for the specified filter and size limit.

Parameters:
sizeLimit - the maximum return size.
filter - filter attributes
Returns:
ArrayList the list of users for given role grant.

getUserProfilePropertyVal

public java.lang.Object getUserProfilePropertyVal(java.lang.String name,
                                                  java.lang.String propName)
Returns the UserProfile property value for the specified user name and property name.

Parameters:
name - the name of user.
propName - the property name.
Returns:
Object the property value object.

saveUserProfile

public void saveUserProfile(java.lang.String userName,
                            java.util.HashMap values)
Saves user profile values for the specified user.

Parameters:
userName - name of the user
values - user profile properties and values

getAnonymousUserName

public java.lang.String getAnonymousUserName()
Returns the name of anonymous user.

Returns:
String name of anonymous user.

getAnonymousUser

public java.security.Principal getAnonymousUser()
Returns ther anonymous user principal.

Returns:
Principal the anonymous principal.

Oracle Fusion Middleware Java API Reference for Oracle ADF Share
11g Release 2 (11.1.2.0.0)

E17486-01

Copyright © 1997, 2011, Oracle. All rights reserved.