public abstract class StaticRuntimeException extends java.lang.RuntimeException implements StaticThrowable
| Modifier | Constructor and Description |
|---|---|
protected |
StaticRuntimeException() |
| Modifier and Type | Method and Description |
|---|---|
java.lang.Throwable |
fillInStackTrace()
Calls into the virtual machine to capture the current stack trace in SO
local memory.
|
java.lang.Throwable |
getCause()
getCause returns the cause of this exception or
null when no cause
was set. |
java.lang.String |
getLocalizedMessage()
Subclasses may override this message to get an error message that is
localized to the default locale.
|
java.lang.String |
getMessage()
get the message describing the problem from SO local memory.
|
java.lang.StackTraceElement[] |
getStackTrace()
Get the stack trace created by fillInStackTrace for this Throwable as an
array of StackTraceElements.
|
java.lang.Throwable |
initCause(java.lang.Throwable causingThrowable)
Initializes the cause to the given Throwable is SO local memory.
|
java.lang.Throwable |
initMessage(java.lang.String message)
Set the message in SO local storage.
|
void |
printStackTrace()
Print stack trace of this Throwable to System.err.
|
void |
printStackTrace(java.io.PrintStream stream)
Print the stack trace of this Throwable to the given stream.
|
void |
printStackTrace(java.io.PrintWriter writer)
Print the stack trace of this Throwable to the given PrintWriter.
|
void |
setStackTrace(java.lang.StackTraceElement[] new_stackTrace)
This method allows overriding the stack trace that was filled during
construction of this object.
|
public java.lang.Throwable initMessage(java.lang.String message)
StaticThrowablejava.lang.Throwable.initMessage in interface StaticThrowablemessage - is the text to save.public java.lang.String getMessage()
StaticThrowablegetMessage in interface StaticThrowablegetMessage in class java.lang.Throwablenull when no
message was set.public java.lang.String getLocalizedMessage()
StaticThrowable
By default it returns getMessage().
getLocalizedMessage in interface StaticThrowablegetLocalizedMessage in class java.lang.ThrowablegetMessage().public java.lang.Throwable initCause(java.lang.Throwable causingThrowable)
StaticThrowableinitCause in interface StaticThrowableinitCause in class java.lang.ThrowablecausingThrowable - the reason why this Throwable gets Thrown.public java.lang.Throwable getCause()
StaticThrowablenull when no cause
was set. The cause is another exception that was caught before this
exception was created.getCause in interface StaticThrowablegetCause in class java.lang.Throwablenull.public java.lang.Throwable fillInStackTrace()
StaticThrowablefillInStackTrace in interface StaticThrowablefillInStackTrace in class java.lang.ThrowableThrowable.public void setStackTrace(java.lang.StackTraceElement[] new_stackTrace)
throws java.lang.NullPointerException
StaticThrowablesetStackTrace in interface StaticThrowablesetStackTrace in class java.lang.Throwablenew_stackTrace - the stack trace to replace be used.java.lang.NullPointerException - when new_stackTrace or any element of
new_stackTrace is null.public java.lang.StackTraceElement[] getStackTrace()
StaticThrowableThe stack trace does not need to contain entries for all methods that are actually on the call stack, the virtual machine may decide to skip some stack trace entries. Even an empty array is a valid result of this function.
Repeated calls of this function without intervening calls to fillInStackTrace will return the same result.
When memory areas of the RTSJ are used (see MemoryArea), and this
Throwable was allocated in a different memory area than the current
allocation context, the resulting stack trace will be allocated in either
the same memory area this was allocated in or the current memory area,
depending on which is the least deeply nested, thereby creating objects
that are assignment compatible with both areas.
getStackTrace in interface StaticThrowablegetStackTrace in class java.lang.Throwablenull.public void printStackTrace()
StaticThrowableThe printed stack trace contains the result of toString() as the first line followed by one line for each stack trace element that contains the name of the method or constructor, optionally followed by the source file name and source file line number when available.
printStackTrace in interface StaticThrowableprintStackTrace in class java.lang.Throwablepublic void printStackTrace(java.io.PrintStream stream)
StaticThrowableThe printed stack trace contains the result of toString() as the first line followed by one line for each stack trace element that contains the name of the method or constructor, optionally followed by the source file name and source file line number when available.
printStackTrace in interface StaticThrowableprintStackTrace in class java.lang.Throwablestream - the stream to print to.public void printStackTrace(java.io.PrintWriter writer)
StaticThrowableThe printed stack trace contains the result of toString() as the first line followed by one line for each stack trace element that contains the name of the method or constructor, optionally followed by the source file name and source file line number when available.
printStackTrace in interface StaticThrowableprintStackTrace in class java.lang.Throwablewriter - the PrintWriter to write to.aicas GmbH, Karlsruhe, Germany —www.aicas.com
Copyright © 2001-2017 aicas GmbH. All Rights Reserved.