Interface PermissionFactory

    • Method Summary

      All Methods Static Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      java.security.Permission construct()
      Construct a new instance of the permission.
      static java.security.Permission constructFromClass​(java.lang.Class<? extends java.security.Permission> permissionClass, java.lang.String targetName, java.lang.String permissionActions)
      Utility method to reflectively construct a permission from a given class.
    • Method Detail

      • construct

        java.security.Permission construct()
        Construct a new instance of the permission. The instance may be cached.
        Returns:
        the permission
      • 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