Class NotAuthorizedException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- oracle.dbtools.plugin.api.security.NotAuthorizedException
-
- All Implemented Interfaces:
java.io.Serializable
public class NotAuthorizedException extends java.lang.RuntimeException
Raised whenever a resource is accessed that the current user does not have permission to access.- Author:
- cdivilly
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description NotAuthorizedException(java.lang.String authorizationConstaintName)
Raises aNotAuthorizedException
condition requiring the user to have authenticated against theAuthorizationConstraint
, chaining thecause
parameter as the underlying cause of the authorization failure.NotAuthorizedException(java.lang.String authorizationConstraintName, AuthorizationError error, java.lang.Throwable cause)
Raises aNotAuthorizedException
condition requiring the user to have authenticated against the specified Privilege.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description AuthorizationError
error()
TheAuthorizationError
.java.lang.String
toString()
-
-
-
Constructor Detail
-
NotAuthorizedException
public NotAuthorizedException(java.lang.String authorizationConstraintName, AuthorizationError error, java.lang.Throwable cause)
Raises aNotAuthorizedException
condition requiring the user to have authenticated against the specified Privilege.- Parameters:
authorizationConstraintName
- The name of theAuthorizationConstraint
that the principal was authorized againsterror
-AuthorizationError
explaining the reason for the authorization failure. May be null.cause
- The underlying cause of the authorization failure.
-
NotAuthorizedException
public NotAuthorizedException(java.lang.String authorizationConstaintName)
Raises aNotAuthorizedException
condition requiring the user to have authenticated against theAuthorizationConstraint
, chaining thecause
parameter as the underlying cause of the authorization failure.- Parameters:
authorizationConstaintName
- The name of theAuthorizationConstraint
that this principal failed authorization for.
-
-
Method Detail
-
error
public AuthorizationError error()
TheAuthorizationError
.- Returns:
AuthorizationError
instance or null, if no error reason specified.
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Throwable
-
-