Top Description Methods
org.jboss.modules.security

public Interface PermissionFactory

Known Direct Implementers
org.jboss.modules.security.ImmediatePermissionFactory, org.jboss.modules.security.LoadedPermissionFactory, org.jboss.modules.security.ModularPermissionFactory
Imports
java.lang.reflect.Constructor, .InvocationTargetException, java.security.Permission

A factory for Permission objects.
Author
David M. Lloyd

Method Summary

Modifier and TypeMethod and Description
public Permission

Returns:

the permission
construct
()

Construct a new instance of the permission.

public static Permission

Returns:

the permission
constructFromClass
(Class<? extends Permission>
the permission class
permissionClass
,
String
the optional target name
targetName
,
String
the optional actions name
permissionActions
)

Utility method to reflectively construct a permission from a given class.

Method Detail

constructback to summary
public Permission construct()

Construct a new instance of the permission. The instance may be cached.

Returns:Permission

the permission

constructFromClassback to summary
public static Permission constructFromClass(Class<? extends Permission> permissionClass, String targetName, String permissionActions) throws IllegalAccessException, InvocationTargetException, InstantiationException, NoSuchMethodException

Utility method to reflectively construct a permission from a given class.

Parameters
permissionClass:Class<? extends Permission>

the permission class

targetName:String

the optional target name

permissionActions:String

the optional actions name

Returns:Permission

the permission

Exceptions
IllegalAccessException:
if the necessary constructor is not accessible
InvocationTargetException:
if the constructor failed
InstantiationException:
if the object could not be instantiated for some reason
NoSuchMethodException:
if none of the candidate constructors exist on the class