public class

PrivilegedActionException

extends Exception
java.lang.Object
   ↳java.lang.Throwable
    ↳java.lang.Exception
     ↳java.security.PrivilegedActionException

Class Overview

PrivilegedActionException wraps exceptions which are thrown from within privileged operations.

Privileged actions which can throw exceptions are of type PrivilegedExceptionAction and are thrown by

    AccessController#doPrivileged(PrivilegedExceptionAction)
    AccessController#doPrivileged(PrivilegedExceptionAction, AccessControlContext)

    Summary

    Public Constructors
    PrivilegedActionException(Exception ex)
    Constructs a new instance of PrivilegedActionException with the cause.
    Public Methods
    Throwable getCause()
    Returns the exception that was thrown by a PrivilegedExceptionAction.
    Exception getException()
    Returns the exception that was thrown by a PrivilegedExceptionAction.
    String toString()
    Returns a string containing a concise, human-readable description of this PrivilegedActionException.
    [Expand]
    Inherited Methods
    From class java.lang.Throwable
    From class java.lang.Object

    Public Constructors

    public PrivilegedActionException (Exception ex)

    Since: API Level 1

    Constructs a new instance of PrivilegedActionException with the cause.

    Parameters
    ex the exception which is the cause for this exception.

    Public Methods

    public Throwable getCause ()

    Since: API Level 1

    Returns the exception that was thrown by a PrivilegedExceptionAction.

    Returns
    • the exception that was thrown by a PrivilegedExceptionAction.

    public Exception getException ()

    Since: API Level 1

    Returns the exception that was thrown by a PrivilegedExceptionAction.

    Returns
    • the exception that was thrown by a PrivilegedExceptionAction.

    public String toString ()

    Since: API Level 1

    Returns a string containing a concise, human-readable description of this PrivilegedActionException.

    Returns
    • a printable representation for this PrivilegedActionException.