Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| JAAS Provider Java API Reference 10g (9.0.4.0.0) B10389-01
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## oracle.security.jazn.realm
Interface UserManager

public interface UserManager

Interface UserManager define the APIs for managing users in a realm.

Here are the properties appliacable for a LDAP-based realm.

Property names | Descriptions
jazn.realm.users.ldap.isExternal | A flag, true or false, to specify whether the users are external to JAZN or not.
jazn.realm.users.ldap.searchBase# | Set the search base to point to the directory subtree where users will be searched. JAZN locates users with a specified name by searching in the subtree, jazn.realm.users.ldap.searchBase, all the objects defined using the user object class if specified, jazn.realm.users.ldap.objectClass, with attribute, jazn.realm.users.ldap.nameAttribute, matching the search value provided by the client.
jazn.realm.users.ldap.nameAttribute# | Set this property to the attribute that uniquely identifies the name of the user.
jazn.realm.users.ldap.objectClass## | Set this property to the name of schema object class that is used to represent a user.

#these properties should be defined for external users (i.e. when jazn.realm.users.ldap.isExternal is "true")
##optional property, it is useful for further restricting the search of users.

Method Summary
`RealmUser` | `createUser(String name)` Create a RealmUser in this realm
`RealmUser` | `createUser(String name, String passwd)` Create a RealmUser in this realm
`void` | `dropUser(String name)` Drops user of the specified name from this realm.
`void` | `dropUser(String name, boolean cascade)` Drops user of the specified name from this realm.
`Realm` | `getRealm()` Returns the Realm reference that this UserManager belongs to.
`RealmUser` | `getUser(String name)` Returns the RealmUser with the specified name
`int` | `getUserCount()` Returns the number of users in this UserManager
`Set` | `getUsers()` Returns the users in this UserManager
`void` | `initialize(Hashtable attributes)` Initialize the UserManager if it's not yet intialized.
`void` | `refresh()` Gives the UserManager a chance to refresh its cache, so updated data will be visible
`void` | `setRealm(Realm realm)` Set the realm that this UserManager is associated with.

Method Detail

### setRealm

    public void setRealm(Realm realm)
                  throws JAZNException

  Set the realm that this UserManager is associated with.
  Parameters:
    `realm` - an instance of Realm
    `JAZNException`

### initialize

    public void initialize(Hashtable attributes)
                    throws JAZNException

  Initialize the UserManager if it's not yet intialized.
  Parameters:
    `attributes` - a possibly null table of attributes and configuration parameters for initialization.
    `JAZNException`

### refresh

    public void refresh()

  Gives the UserManager a chance to refresh its cache, so updated data will be visible

### getRealm

    public Realm getRealm()

  Returns the Realm reference that this UserManager belongs to.

### getUsers

    public Set getUsers()
                 throws JAZNException

  Returns the users in this UserManager
  Returns:
    a Set of RealmUser instances.
  Throws:
    `JAZNNamingException` - if a naming Exception is encountered.
    `JAZNException`

### getUserCount

    public int getUserCount()
                     throws JAZNException

  Returns the number of users in this UserManager
  Returns:
    the number of users in this UserManager
  Throws:
    `JAZNNamingException` - if a naming Exception is encountered.
    `JAZNException`

### getUser

    public RealmUser getUser(String name)
                      throws JAZNException

  Returns the RealmUser with the specified name
  Throws:
    `JAZNNamingException` - if a naming Exception is encountered.
    `JAZNException`

### createUser

    public RealmUser createUser(String name)
                         throws JAZNException

  Create a RealmUser in this realm
  Throws:
    `UnsupportedOperationException` - is thrown if users are not modifiable.
    `JAZNNamingException` - if a naming Exception is encountered.
    `SecurityException` - if the caller does not have permission to invoke this method
    `JAZNException`

### createUser

    public RealmUser createUser(String name,
    String passwd)
                         throws JAZNException

  Create a RealmUser in this realm
  Parameters:
    `passwd` - password
  Throws:
    `UnsupportedOperationException` - is thrown if users are not modifiable.
    `JAZNNamingException` - if a naming Exception is encountered.
    `SecurityException` - if the caller does not have permission to invoke this method
    `JAZNException`

### dropUser

    public void dropUser(String name)
                  throws JAZNException

  Drops user of the specified name from this realm.
  Parameters:
    `name` - name of the user to be dropped from the realm.
  Throws:
    `UnsupportedOperationException` - is thrown if users are not modifiable in this realm.
    `JAZNNamingException` - if a naming Exception is encountered.
    `JAZNObjectNotFoundException` - if the user cannot be found in this realm.
    `SecurityException` - if the caller does not have permission to invoke this method
    `JAZNException`

### dropUser

    public void dropUser(String name,
                         boolean cascade)
                  throws JAZNException

  Drops user of the specified name from this realm.
  Parameters:
    `name` - name of the user to be dropped from the realm.
    `cascade` - if `true`, the user will be removed from roles who has the user as a memeber, and all policy entries related to the user will be removed as well.
  Throws:
    `UnsupportedOperationException` - is thrown if users are not modifiable in this realm.
    `JAZNNamingException` - if a naming Exception is encountered.
    `JAZNObjectNotFoundException` - if the user cannot be found in this realm.
    `SecurityException` - if the caller does not have permission to invoke this method
    `JAZNException`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| JAAS Provider Java API Reference 10g (9.0.4.0.0) B10389-01
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright 2002, 2003 Oracle Corporation. All Rights Reserved.