|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectCoreException
org.eclipse.wst.jsdt.core.JavaScriptModelException
public class JavaScriptModelException
A checked exception representing a failure in the JavaScript model. JavaScript model exceptions contain a JavaScript-specific status object describing the cause of the exception.
This class is not intended to be subclassed by clients. Instances of this class are automatically created by the JavaScript model when problems arise, so there is generally no need for clients to create instances.
IJavaScriptModelStatus
,
Provisional API: This class/interface is part of an interim API that is still under development and expected to
change significantly before reaching stability. It is being made available at this early stage to solicit feedback
from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken
(repeatedly) as the API evolves.
Constructor Summary | |
---|---|
JavaScriptModelException(CoreException exception)
Creates a JavaScript model exception for the given CoreException . |
|
JavaScriptModelException(java.lang.Throwable e,
int code)
Creates a JavaScript model exception that wrappers the given Throwable . |
Method Summary | |
---|---|
java.lang.Throwable |
getException()
Returns the underlying Throwable that caused the failure. |
IJavaScriptModelStatus |
getJavaScriptModelStatus()
Returns the JavaScript model status object for this exception. |
boolean |
isDoesNotExist()
Returns whether this exception indicates that a JavaScript model element does not exist. |
void |
printStackTrace(java.io.PrintStream output)
Prints this exception's stack trace to the given print stream. |
void |
printStackTrace(java.io.PrintWriter output)
Prints this exception's stack trace to the given print writer. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public JavaScriptModelException(java.lang.Throwable e, int code)
Throwable
.
The exception contains a JavaScript-specific status object with severity
IStatus.ERROR
and the given status code.
e
- the Throwable
code
- one of the JavaScript-specific status codes declared in
IJavaScriptModelStatusConstants
IJavaScriptModelStatusConstants
,
org.eclipse.core.runtime.IStatus#ERROR
public JavaScriptModelException(CoreException exception)
CoreException
.
Equivalent to
JavaScriptModelException(exception,IJavaScriptModelStatusConstants.CORE_EXCEPTION
.
exception
- the CoreException
Method Detail |
---|
public java.lang.Throwable getException()
Throwable
that caused the failure.
Throwable
, or null
if the
direct case of the failure was at the JavaScript model layerpublic IJavaScriptModelStatus getJavaScriptModelStatus()
(IJavaScriptModelStatus) getStatus()
.
public boolean isDoesNotExist()
IJavaScriptModelStatusConstants.ELEMENT_DOES_NOT_EXIST
or
IJavaScriptModelStatusConstants.ELEMENT_NOT_ON_CLASSPATH
.
This is a convenience method.
true
if this exception indicates that a JavaScript model
element does not existIJavaScriptModelStatus.isDoesNotExist()
,
IJavaScriptModelStatusConstants.ELEMENT_DOES_NOT_EXIST
,
IJavaScriptModelStatusConstants.ELEMENT_NOT_ON_CLASSPATH
public void printStackTrace(java.io.PrintStream output)
output
- the print streampublic void printStackTrace(java.io.PrintWriter output)
output
- the print writerpublic java.lang.String toString()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |