Package org.apache.groovy.json.internal
Class Exceptions.JsonInternalException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
groovy.json.JsonException
org.apache.groovy.json.internal.Exceptions.JsonInternalException
- All Implemented Interfaces:
Serializable
- Enclosing class:
- Exceptions
Runtime exception used inside the JSON internals to simplify propagation.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionJsonInternalException(String message) Creates an exception with the supplied message.JsonInternalException(String message, Throwable cause) Creates an exception with the supplied message and cause.JsonInternalException(Throwable cause) Creates an exception that wraps another throwable. -
Method Summary
Modifier and TypeMethodDescriptiongetCause()Returns the wrapped cause.Returns the localized message.Returns the message, including the wrapped cause summary when present.Returns the wrapped stack trace when a cause is present.voidLogs the wrapped stack trace.voidPrints the wrapped stack trace to the supplied stream.voidPrints the wrapped stack trace to the supplied writer.Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getSuppressed, initCause, setStackTrace, toString
-
Constructor Details
-
JsonInternalException
Creates an exception with the supplied message.- Parameters:
message- the exception message
-
JsonInternalException
Creates an exception with the supplied message and cause.- Parameters:
message- the exception messagecause- the wrapped cause
-
JsonInternalException
Creates an exception that wraps another throwable.- Parameters:
cause- the wrapped cause
-
-
Method Details
-
printStackTrace
Prints the wrapped stack trace to the supplied stream.- Overrides:
printStackTracein classThrowable- Parameters:
s- the target stream
-
getMessage
Returns the message, including the wrapped cause summary when present.- Overrides:
getMessagein classThrowable- Returns:
- the formatted exception message
-
getLocalizedMessage
Returns the localized message.- Overrides:
getLocalizedMessagein classThrowable- Returns:
- the localized message
-
getStackTrace
Returns the wrapped stack trace when a cause is present.- Overrides:
getStackTracein classThrowable- Returns:
- the effective stack trace
-
getCause
Returns the wrapped cause. -
printStackTrace
Prints the wrapped stack trace to the supplied writer.- Overrides:
printStackTracein classThrowable- Parameters:
s- the target writer
-
printStackTrace
public void printStackTrace()Logs the wrapped stack trace.- Overrides:
printStackTracein classThrowable
-