A ModelMBean implementation for the org.apache.catalina.users.SparseUserDatabase
component. The main difference is that the MBeans are created on demand (for example, the findUser method would
register the corresponding user and make it available for management. All the MBeans created for users, groups and
roles are then discarded when save is invoked.
| Modifier and Type | Field and Description |
|---|---|
| protected final ManagedBean | managed
The |
| protected final ManagedBean | managedGroup
The |
| protected final ManagedBean | managedRole
The |
| protected final ManagedBean | managedUser
The |
| protected final MBeanServer | mserver
The |
| protected final Registry | registry
The configuration information registry for our managed beans. |
| private static final StringManager |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public String | Returns: the new group object nameGroup name of the new group groupname, String Description of the new group description)Create a new Group and return the corresponding MBean Name. |
| public String | Returns: the new role object nameGroup name of the new group rolename, String Description of the new group description)Create a new Role and return the corresponding MBean Name. |
| public String | Returns: the new user object nameUser name of the new user username, String Password for the new user password, String Full name for the new user fullName)Create a new User and return the corresponding MBean Name. |
| public String | |
| public String | |
| public String | |
| public String[] | |
| public String[] | |
| public String[] | |
| public void | removeGroup(String
Group name to remove groupname)Remove an existing group and destroy the corresponding MBean. |
| public void | removeRole(String
Role name to remove rolename)Remove an existing role and destroy the corresponding MBean. |
| public void | removeUser(String
User name to remove username)Remove an existing user and destroy the corresponding MBean. |
| public void |
| managed | back to summary |
|---|---|
| protected final ManagedBean managed The | |
| managedGroup | back to summary |
|---|---|
| protected final ManagedBean managedGroup The | |
| managedRole | back to summary |
|---|---|
| protected final ManagedBean managedRole The | |
| managedUser | back to summary |
|---|---|
| protected final ManagedBean managedUser The | |
| mserver | back to summary |
|---|---|
| protected final MBeanServer mserver The | |
| registry | back to summary |
|---|---|
| protected final Registry registry The configuration information registry for our managed beans. | |
| sm | back to summary |
|---|---|
| private static final StringManager sm | |
| SparseUserDatabaseMBean | back to summary |
|---|---|
| public SparseUserDatabaseMBean() | |
| createGroup | back to summary |
|---|---|
| public String createGroup(String groupname, String description) Create a new Group and return the corresponding MBean Name. | |
| createRole | back to summary |
|---|---|
| public String createRole(String rolename, String description) Create a new Role and return the corresponding MBean Name. | |
| createUser | back to summary |
|---|---|
| public String createUser(String username, String password, String fullName) Create a new User and return the corresponding MBean Name. | |
| findGroup | back to summary |
|---|---|
| public String findGroup(String groupname) Return the MBean Name for the specified group name (if any); otherwise return | |
| findRole | back to summary |
|---|---|
| public String findRole(String rolename) Return the MBean Name for the specified role name (if any); otherwise return | |
| findUser | back to summary |
|---|---|
| public String findUser(String username) Return the MBean Name for the specified user name (if any); otherwise return | |
| getGroups | back to summary |
|---|---|
public String[] getGroups()
| |
| getRoles | back to summary |
|---|---|
public String[] getRoles()
| |
| getUsers | back to summary |
|---|---|
public String[] getUsers()
| |
| removeGroup | back to summary |
|---|---|
| public void removeGroup(String groupname) Remove an existing group and destroy the corresponding MBean.
| |
| removeRole | back to summary |
|---|---|
| public void removeRole(String rolename) Remove an existing role and destroy the corresponding MBean.
| |
| removeUser | back to summary |
|---|---|
| public void removeUser(String username) Remove an existing user and destroy the corresponding MBean.
| |
| save | back to summary |
|---|---|
| public void save() Call actual save and unregister all obsolete beans. | |