public class InstantiationPermissions extends Object implements IClusterable
Constructor and Description |
---|
InstantiationPermissions() |
Modifier and Type | Method and Description |
---|---|
<T extends Component> |
authorize(Class<T> componentClass,
Roles rolesToAdd)
Gives the given role permission to instantiate the given class.
|
<T extends Component> |
authorizeAll(Class<T> componentClass)
Gives all roles permission to instantiate the given class.
|
<T extends IRequestableComponent> |
authorizedRoles(Class<T> componentClass)
Gets the roles that have a binding with the given component class.
|
protected Map<Class<? extends Component>,Roles> |
getRolesForComponentClass() |
<T extends Component> |
unauthorize(Class<T> componentClass,
Roles rolesToRemove)
Removes permission for the given role to instantiate the given class.
|
public final <T extends Component> void authorize(Class<T> componentClass, Roles rolesToAdd)
T
- componentClass
- The component classrolesToAdd
- The roles to addpublic final <T extends Component> void authorizeAll(Class<T> componentClass)
T
- componentClass
- The component classpublic <T extends IRequestableComponent> Roles authorizedRoles(Class<T> componentClass)
T
- componentClass
- the component classpublic final <T extends Component> void unauthorize(Class<T> componentClass, Roles rolesToRemove)
T
- componentClass
- The classrolesToRemove
- The role to denyCopyright © 2006–2022 Apache Software Foundation. All rights reserved.