public class UserMBean extends BaseModelMBean
A ModelMBean implementation for the
org.apache.catalina.User
component.
Modifier and Type | Field and Description |
---|---|
protected ManagedBean |
managed
The
ManagedBean information describing this MBean. |
protected Registry |
registry
The configuration information registry for our managed beans.
|
attributeBroadcaster, generalBroadcaster, managedBean, oname, resource, resourceType
Constructor and Description |
---|
UserMBean()
Construct a
ModelMBean with default
ModelMBeanInfo information. |
Modifier and Type | Method and Description |
---|---|
void |
addGroup(String groupname)
Add a new
Group to those this user belongs to. |
void |
addRole(String rolename)
Add a new
Role to those this user belongs to. |
String[] |
getGroups()
Return the MBean Names of all groups this user is a member of.
|
String[] |
getRoles()
Return the MBean Names of all roles assigned to this user.
|
void |
removeGroup(String groupname)
Remove a
Group from those this user belongs to. |
void |
removeRole(String rolename)
Remove a
Role from those this user belongs to. |
addAttributeChangeNotificationListener, addNotificationListener, getAttribute, getAttributes, getClassName, getJmxName, getManagedResource, getMBeanInfo, getModelerType, getNotificationInfo, getObjectName, invoke, postDeregister, postRegister, preDeregister, preRegister, removeAttributeChangeNotificationListener, removeAttributeChangeNotificationListener, removeNotificationListener, removeNotificationListener, removeNotificationListener, sendAttributeChangeNotification, sendAttributeChangeNotification, sendNotification, sendNotification, setAttribute, setAttributes, setManagedBean, setManagedResource, toString
protected Registry registry
protected ManagedBean managed
ManagedBean
information describing this MBean.public UserMBean() throws MBeanException, RuntimeOperationsException
ModelMBean
with default
ModelMBeanInfo
information.MBeanException
- if the initializer of an object
throws an exceptionRuntimeOperationsException
- if an IllegalArgumentException
occurspublic String[] getGroups()
public String[] getRoles()
public void addGroup(String groupname)
Group
to those this user belongs to.groupname
- Group name of the new grouppublic void addRole(String rolename)
Role
to those this user belongs to.rolename
- Role name of the new rolepublic void removeGroup(String groupname)
Group
from those this user belongs to.groupname
- Group name of the old groupCopyright © 2000-2021 Apache Software Foundation. All Rights Reserved.