constructFromClass
static java.security.Permission constructFromClass(java.lang.Class<? extends java.security.Permission> permissionClass,
java.lang.String targetName,
java.lang.String permissionActions)
throws java.lang.IllegalAccessException,
java.lang.reflect.InvocationTargetException,
java.lang.InstantiationException,
java.lang.NoSuchMethodException
Utility method to reflectively construct a permission from a given class.
- Parameters:
permissionClass - the permission class
targetName - the optional target name
permissionActions - the optional actions name
- Returns:
- the permission
- Throws:
java.lang.IllegalAccessException - if the necessary constructor is not accessible
java.lang.reflect.InvocationTargetException - if the constructor failed
java.lang.InstantiationException - if the object could not be instantiated for some reason
java.lang.NoSuchMethodException - if none of the candidate constructors exist on the class