Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## ix.util
Class RethrownException

    java.lang.Object
      java.lang.Throwable
          java.lang.Exception
              java.lang.RuntimeException
                  ix.util.RethrownException

All Implemented Interfaces:
  java.io.Serializable

    public class RethrownException

extends java.lang.RuntimeException

An unchecked exception used to wrap other Throwables when they're rethrown. Usually the wrapped Throwable is a checked exception that should not or could not be handled locally.

See Also:
  Serialized Form

Field Summary
`(package private) java.lang.Throwable` | `target`

Constructor Summary
`RethrownException(java.lang.String messagePrefix, java.lang.Throwable target)` Constructs an exception with the specified target and a message formed by concatenating the prefix, followed by a space, to the result of calling `Debug.describeException(Throwable)` on the target.
`RethrownException(java.lang.Throwable target)` Constructs an exception with a description of the target as its message.
`RethrownException(java.lang.Throwable target, java.lang.String message)` Constructs an exception with the specified target and message.

Method Summary
`java.lang.Throwable` | `getException()` Returns the Throwable that was wrapped in this exception.
`void` | `printStackTrace()` Prints the stack trace of the wrapped exception to System.err.
`void` | `printStackTrace(java.io.PrintStream s)` Prints the stack trace of the wrapped exception.
`void` | `printStackTrace(java.io.PrintWriter w)` Prints the stack trace of the wrapped exception.

Methods inherited from class java.lang.Throwable
`fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, setStackTrace, toString`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Field Detail

### target

    java.lang.Throwable target

Constructor Detail

### RethrownException

    public RethrownException(java.lang.Throwable target)

  Constructs an exception with a description of the target as its message.

  See Also:
    `Debug.describeException(Throwable)`

### RethrownException

    public RethrownException(java.lang.Throwable target,
                             java.lang.String message)

  Constructs an exception with the specified target and message. The message should be a description of the problem that does not require a separate look at the target exception.

### RethrownException

    public RethrownException(java.lang.String messagePrefix,
                             java.lang.Throwable target)

  Constructs an exception with the specified target and a message formed by concatenating the prefix, followed by a space, to the result of calling `Debug.describeException(Throwable)` on the target.

Method Detail

### getException

    public java.lang.Throwable getException()

  Returns the Throwable that was wrapped in this exception.

### printStackTrace

    public void printStackTrace()

  Prints the stack trace of the wrapped exception to System.err.

  Overrides:
    `printStackTrace` in class `java.lang.Throwable`

### printStackTrace

    public void printStackTrace(java.io.PrintStream s)

  Prints the stack trace of the wrapped exception.

  Overrides:
    `printStackTrace` in class `java.lang.Throwable`

### printStackTrace

    public void printStackTrace(java.io.PrintWriter w)

  Prints the stack trace of the wrapped exception.

  Overrides:
    `printStackTrace` in class `java.lang.Throwable`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD