Novell exteNd
Director 5.2 API

com.sssw.fw.usermgr.api
Interface EbiUserManager


public interface EbiUserManager

This provides an interface for the user manager.


Method Summary
 boolean addUserMeta(EbiContext ctx, EbiUserMeta userMeta)
          Adds the user metadata.
 EbiUserInfo createUser(EbiContext context)
          Creates a user info object for the authenticated user associated with the security context.
 boolean createUser(EbiContext ctx, EbiUserInfo userInfo)
          Adds the new EbiUserInfo object to the user service's persistence store.
 EbiUserMeta getClonedUserMeta(EbiContext ctx)
          Gets a EbiUserMeta object for modify.
 int getTotalUsers(EbiContext context, String realmName)
          Returns the total number of users that are available for a specified realm.
 EbiUserInfo getUserBlobAttributes(EbiContext context, EbiUserInfo userInfo)
          Gets user blob attribute contents.
 EbiUserInfo getUserExtendedAttributes(EbiContext context, EbiUserInfo userInfo, boolean light)
          Gets user extended attributes.
 EbiUserInfo getUserInfoByUserID(EbiContext ctx, String userID)
          Gets a user info object by user ID.
 EbiUserInfo getUserInfoByUserID(EbiContext ctx, String userID, String realmName)
          Gets a user info object for specified user.
 EbiUserInfo getUserInfoByUserUUID(EbiContext ctx, String userIID)
          Gets a user info object by specified user UUID.
 EbiUserInfo[] getUserList(EbiContext ctx)
          Deprecated. EbiUserManager.getUserList(EbiContext, String)
 EbiUserInfo[] getUserList(EbiContext ctx, EbiUserQuery query)
          Gets a list of user info objects by a specified query.
 EbiUserInfo[] getUserList(EbiContext ctx, String realmName)
          Gets a list of user info objects for a specified realm.
 EbiUserMeta getUserMeta()
          Gets an EbiUserMeta object in read-only mode.
 EbiUserMeta getUserMeta(EbiContext ctx)
          Gets a EbiUserMeta object in readonly mode.
 boolean isBaseAttrSynched(EbiContext ctx)
          Determines if user base attributes are synchronized with a directory.
 boolean modifyUser(EbiContext ctx, EbiUserInfo userInfo)
          Modifies the user info for an existing user.
 boolean modifyUserMeta(EbiContext ctx, EbiUserMeta userMeta)
          Modifies the user metadata.
 boolean removeUser(EbiContext ctx, String userIID)
          Remove a user from the user service's persistence store.
 boolean removeUser(EbiContext ctx, String userID, String realmName)
          Remove a user from the user service's persistence store.
 boolean removeUserMeta(EbiContext ctx)
          Removes the user meta.
 int synchBaseAttributes(EbiContext ctx)
          Synchronizes user base attributes with a directory server Base attributes include FirstName, LastName and EmailAddress.
 

Method Detail

getUserInfoByUserID

public EbiUserInfo getUserInfoByUserID(EbiContext ctx,
                                       String userID,
                                       String realmName)
                                throws EboUnrecoverableSystemException,
                                       EboSecurityException
Gets a user info object for specified user.
Only user service administrators with READ permission or user him/herself can access the specified user info object.
Parameters:
ctx - an EbiContext object.
userID - a user ID.
realmName - a realm Name.
Returns:
an EbiUserInfo object for the user from specified realm.

getUserInfoByUserID

public EbiUserInfo getUserInfoByUserID(EbiContext ctx,
                                       String userID)
                                throws EboUnrecoverableSystemException,
                                       EboSecurityException
Gets a user info object by user ID.
Only user service administrators with READ permission or user him/herself can access the specified user info object.
Parameters:
ctx - an EbiContext object.
userID - a user ID.
Returns:
an EbiUserInfo object for the specified user from primary realm.

getUserInfoByUserUUID

public EbiUserInfo getUserInfoByUserUUID(EbiContext ctx,
                                         String userIID)
                                  throws EboUnrecoverableSystemException,
                                         EboSecurityException
Gets a user info object by specified user UUID.
Only user service administrators with READ permission or user him/herself can access the user info object.
Parameters:
ctx - an EbiContext object.
userIID - a user UUID.
Returns:
the EbiUserInfo object for the specified user.

createUser

public EbiUserInfo createUser(EbiContext context)
                       throws EboUnrecoverableSystemException,
                              EboSecurityException
Creates a user info object for the authenticated user associated with the security context. This method stores the created info object persistly and also caches it in the current client session.
This method checks user service administrators' CREATE permission.
Parameters:
ctx - an EbiContext object
Returns:
an EbiUserInfo object if it is created successfully, false otherwise.

createUser

public boolean createUser(EbiContext ctx,
                          EbiUserInfo userInfo)
                   throws EboUnrecoverableSystemException,
                          EboSecurityException
Adds the new EbiUserInfo object to the user service's persistence store.
This method checks user service administrators' CREATE permission.
Parameters:
ctx - an EbiContext object
usrInfo - an EbiUserInfo object for the new user.
Returns:
true if the user personalize account for the specified user is created successfully, false otherwise.

modifyUser

public boolean modifyUser(EbiContext ctx,
                          EbiUserInfo userInfo)
                   throws EboUnrecoverableSystemException,
                          EboSecurityException
Modifies the user info for an existing user.
This method checks user service administrators' UPDATE permission.
Parameters:
ctx - an EbiContext object.
userInfo - an EbiUserInfo object for the specified user.
Returns:
true if the user info for the specified user is modified successfully.

removeUser

public boolean removeUser(EbiContext ctx,
                          String userID,
                          String realmName)
                   throws EboUnrecoverableSystemException,
                          EboSecurityException
Remove a user from the user service's persistence store.
This method checks user service administrators' DELETE permission.
Parameters:
ctx - an EbiContext object.
userID - a user ID.
realmName - (optional) a realm name, if not provided, it will use the primary realm.
Returns:
true if the specified user is removed successfully.

removeUser

public boolean removeUser(EbiContext ctx,
                          String userIID)
                   throws EboUnrecoverableSystemException,
                          EboSecurityException
Remove a user from the user service's persistence store.
This method checks user service administrators' DELETE permission.
Parameters:
ctx - an EbiContext object.
userIID - a user IID.
Returns:
true if the specified user is removed successfully.

getUserList

public EbiUserInfo[] getUserList(EbiContext ctx,
                                 EbiUserQuery query)
                          throws EboUnrecoverableSystemException,
                                 EboSecurityException
Gets a list of user info objects by a specified query.
This method checks user service administrators' READ permission.
Parameters:
ctx - an EbiContext object.
query - an EbiUserQuery object that contains the search criteria.
Returns:
a list EbiUserInfo objects from the search result.

getUserList

public EbiUserInfo[] getUserList(EbiContext ctx,
                                 String realmName)
                          throws EboUnrecoverableSystemException,
                                 EboSecurityException
Gets a list of user info objects for a specified realm.
Parameters:
ctx - an EboContext object.
realmName - a realm name.
Returns:
a list EbiUserInfo objects for a specified realm. (Only gets UserID and UserIIDs)

getUserList

public EbiUserInfo[] getUserList(EbiContext ctx)
                          throws EboUnrecoverableSystemException,
                                 EboSecurityException
Deprecated. EbiUserManager.getUserList(EbiContext, String)

Gets a list of user info objects from the user service's persistence store.
Parameters:
ctx - an EboContext object.
Returns:
a list EbiUserInfo objects. (Only gets UserID and UserIIDs)

getTotalUsers

public int getTotalUsers(EbiContext context,
                         String realmName)
                  throws EboUnrecoverableSystemException,
                         EboSecurityException
Returns the total number of users that are available for a specified realm.
Parameters:
context - an EbiContext object.
realmName - a realm name.
Returns:
an integer representing the total number of users.

getUserExtendedAttributes

public EbiUserInfo getUserExtendedAttributes(EbiContext context,
                                             EbiUserInfo userInfo,
                                             boolean light)
                                      throws EboUnrecoverableSystemException,
                                             EboSecurityException
Gets user extended attributes. i.e. attribute values that are stored in either PROFILEUSERFIELDVALUES table or PROFILEUSERCONTENTS table.
Parameters:
context - an EbiContext object.
userInfo - an EbiUserInfo object that does not yet fetched user extended attribute data yet.
light - true if not to retrieve user blob attributes.
Returns:
the EbiUserInfo provided from caller and filled in with user extended attribute values and user blob attribute contants if requested.

getUserBlobAttributes

public EbiUserInfo getUserBlobAttributes(EbiContext context,
                                         EbiUserInfo userInfo)
                                  throws EboUnrecoverableSystemException,
                                         EboSecurityException
Gets user blob attribute contents.
Parameters:
context - an EbiContext object.
userInfo - an EbiUserInfo object that does not yet fetched user blob attribute data yet.
Returns:
the EbiUserInfo provided from caller and filled in with the user blob attribute contents.

synchBaseAttributes

public int synchBaseAttributes(EbiContext ctx)
                        throws EboUnrecoverableSystemException,
                               EboSecurityException
Synchronizes user base attributes with a directory server Base attributes include FirstName, LastName and EmailAddress.
Parameters:
ctx - an EbiContext object.
Returns:
a count of how many user elements were modified

isBaseAttrSynched

public boolean isBaseAttrSynched(EbiContext ctx)
                          throws EboUnrecoverableSystemException,
                                 EboSecurityException
Determines if user base attributes are synchronized with a directory. Base attributes include FirstName, LastName and EmailAddress.
Parameters:
ctx - an EbiContext object.
Returns:
whether the user subsystem supports synchronization of base attributes with the directory.

getUserMeta

public EbiUserMeta getUserMeta()
                        throws EboUnrecoverableSystemException,
                               EboSecurityException
Gets an EbiUserMeta object in read-only mode.

this call assumes that the EbiUserMeta object is already cached in the user manager.

Returns:
an EbiUserMeta object.

getUserMeta

public EbiUserMeta getUserMeta(EbiContext ctx)
                        throws EboUnrecoverableSystemException,
                               EboSecurityException
Gets a EbiUserMeta object in readonly mode.
Parameters:
ctx - an EbiContext object.
Returns:
an EbiUserMeta object.

getClonedUserMeta

public EbiUserMeta getClonedUserMeta(EbiContext ctx)
                              throws EboUnrecoverableSystemException,
                                     EboSecurityException
Gets a EbiUserMeta object for modify.
Parameters:
ctx - an EbiContext object.
Returns:
an EbiUserMeta object.

addUserMeta

public boolean addUserMeta(EbiContext ctx,
                           EbiUserMeta userMeta)
                    throws EboUnrecoverableSystemException,
                           EboSecurityException
Adds the user metadata.
This method checks user service administrators' WRITE permission.
Parameters:
ctx - an EbiContext object.
userMeta - an EbiUserMeta object.
Returns:
true if the user metadata is added to database successfully, false otherwise.

modifyUserMeta

public boolean modifyUserMeta(EbiContext ctx,
                              EbiUserMeta userMeta)
                       throws EboUnrecoverableSystemException,
                              EboSecurityException
Modifies the user metadata. This method checks user service administrators' WRITE permission.
Parameters:
ctx - an EbiContext object.
userMeta - an EbiUserMeta object.
Returns:
true if the user metadata is modified to database successfully, false otherwise.

removeUserMeta

public boolean removeUserMeta(EbiContext ctx)
                       throws EboUnrecoverableSystemException,
                              EboSecurityException
Removes the user meta. This method checks user service administrators' WRITE permission.
Parameters:
ctx - an EbiContext object.

Novell exteNd
Director 5.2 API