Class RejectedAccessException

    • Constructor Detail

      • RejectedAccessException

        public RejectedAccessException​(String type,
                                       String details,
                                       String info)
        Rejects access to a well-described script element. Normally called from StaticWhitelist.rejectMethod(java.lang.reflect.Method) or similar.
        type - e.g. field
        details - e.g. some.Class fieldName
        info - some additional information if appropriate
      • RejectedAccessException

        public RejectedAccessException​(String message)
        Rejects access to something which the current StaticWhitelist format could not describe.
        message - a descriptive message in no particular format
    • Method Detail

      • getSignature

        public String getSignature()
        Gets the signature of the member to which access was rejected.
        a line in the format understood by StaticWhitelist, or null in case something was rejected for which a known exemption is not available
      • isDangerous

        public boolean isDangerous()
        True if getSignature() is non-null but it would be a bad idea for an administrator to approve it.
      • setDangerous

        public void setDangerous​(boolean dangerous)
        You may set this flag if you think it would be a security risk for this signature to be approved.
        IllegalArgumentException - in case you tried to set this to true when using the nonspecific RejectedAccessException(String) constructor