com.sun.identity.um
Class User

java.lang.Object
  |
  +--com.sun.identity.um.Common
        |
        +--com.sun.identity.um.User

public final class User
extends Common

The User class provides methods to manage user


Method Summary
 void activate()
          Activates the user.
 void assignAssignableDynamicGroup(java.lang.String assignableDynamicGroupDN)
          Assigns a assignable dynamic group to the user.
 void assignRole(java.lang.String roleDN)
          Assigns a role to the user.
 void assignStaticGroup(java.lang.String groupDN)
          Assigns a static group to the user.
 void deactivate()
          Deactivates the user.
 java.util.Set getAssignableDynamicGroupDNs()
          Gets all the assignable dynamic groups the user is in.
 java.util.Set getRoleDNs()
          Gets all the roles the user is in.
 java.util.Set getStaticGroupDNs()
          Gets all the static groups the user is in.
 boolean isActivated()
          Returns true if the user is activated.
 void removeAssignableDynamicGroup(java.lang.String assignableDynamicGroupDN)
          Removes a assignable dynamic group that is assigned to the user.
 void removeRole(java.lang.String roleDN)
          Removes a role that is assigned to the user.
 void removeStaticGroup(java.lang.String groupDN)
          Removes a static group that is assigned to the user.
 
Methods inherited from class com.sun.identity.um.Common
assignServices, delete, delete, getAssignedServices, getAttributes, getAttributes, getDN, getOrganizationDN, getParentDN, getServiceAttributes, getServiceStatus, isExists, modifyService, removeAttributes, setAttributes, setServiceStatus, store, unassignServices
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getRoleDNs

public java.util.Set getRoleDNs()
                         throws UMException,
                                SSOException
Gets all the roles the user is in.
Returns:
The Set of role DN's the user is in.
Throws:
UMException - if unable to get the roles
SSOException - if ssotoken is invalid

assignRole

public void assignRole(java.lang.String roleDN)
                throws UMException,
                       SSOException
Assigns a role to the user.
Parameters:
roleDN - The role DN that the user is assigned to.
Throws:
UMException - if unable to get the roles
SSOException - if ssotoken is invalid

removeRole

public void removeRole(java.lang.String roleDN)
                throws UMException,
                       SSOException
Removes a role that is assigned to the user.
Parameters:
roleDN - The role DN that the user is assigned to.
Throws:
UMException - if unable to get the roles
SSOException - if ssotoken is invalid

getStaticGroupDNs

public java.util.Set getStaticGroupDNs()
                                throws UMException,
                                       SSOException
Gets all the static groups the user is in.
Returns:
The Set of static group DN's the user is in.
Throws:
UMException - if unable to get the roles
SSOException - if ssotoken is invalid

assignStaticGroup

public void assignStaticGroup(java.lang.String groupDN)
                       throws UMException,
                              SSOException
Assigns a static group to the user.
Parameters:
groupDN - The static group DN that the user is assigned to.
Throws:
UMException - if unable to get the roles
SSOException - if ssotoken is invalid

removeStaticGroup

public void removeStaticGroup(java.lang.String groupDN)
                       throws UMException,
                              SSOException
Removes a static group that is assigned to the user.
Parameters:
groupDN - The static group DN that the user is assigned to.
Throws:
UMException - if unable to get the roles
SSOException - if ssotoken is invalid

getAssignableDynamicGroupDNs

public java.util.Set getAssignableDynamicGroupDNs()
                                           throws UMException,
                                                  SSOException
Gets all the assignable dynamic groups the user is in.
Returns:
The Set of assignable dynamic group DN's the user is in.
Throws:
UMException - if there is an internal error in the AM Store
SSOException - if the sign on is no longer valid

assignAssignableDynamicGroup

public void assignAssignableDynamicGroup(java.lang.String assignableDynamicGroupDN)
                                  throws UMException,
                                         SSOException
Assigns a assignable dynamic group to the user.
Parameters:
assignableDynamicGroupDN - The assignable dynamic group DN that the user is assigned to.
Throws:
UMException - if there is an internal error in the AM Store
SSOException - if the sign on is no longer valid

removeAssignableDynamicGroup

public void removeAssignableDynamicGroup(java.lang.String assignableDynamicGroupDN)
                                  throws UMException,
                                         SSOException
Removes a assignable dynamic group that is assigned to the user.
Parameters:
assignableDynamicGroupDN - The assignable dynamic group DN that the user is assigned to.
Throws:
UMException - if there is an internal error in the AM Store
SSOException - if the sign on is no longer valid

activate

public void activate()
              throws UMException,
                     SSOException
Activates the user.
Throws:
UMException - if unable to get the roles
SSOException - if ssotoken is invalid

deactivate

public void deactivate()
                throws UMException,
                       SSOException
Deactivates the user.
Throws:
UMException - if unable to get the roles
SSOException - if ssotoken is invalid

isActivated

public boolean isActivated()
                    throws UMException,
                           SSOException
Returns true if the user is activated.
Returns:
true if the user is activated.
Throws:
UMException - if there is an internal error in the AM Store
SSOException - if the sign on is no longer valid