Top Description Fields Constructors Methods
bsh

public Class EvalError

extends Exception
Class Inheritance
Known Direct Subclasses
bsh.TargetError, bsh.ParseException

EvalError indicates that we cannot continue evaluating the script or the script has thrown an exception. EvalError may be thrown for a script syntax error, an evaluation error such as referring to an undefined variable, an internal error.

See Also
TargetError

Field Summary

Modifier and TypeField and Description
pack-priv CallStack
pack-priv String
pack-priv SimpleNode

Constructor Summary

AccessConstructor and Description
public
EvalError(String s, SimpleNode node, CallStack callstack)

Method Summary

Modifier and TypeMethod and Description
public int
public String
public String
public String
getMessage()

Overrides java.lang.Throwable.getMessage.

Returns the detail message string of this throwable.
pack-priv SimpleNode
getNode()

The error has trace info associated with it.

public String
protected void
prependMessage(String s)

Prepend the message if it is non-null.

public void
reThrow(String msg)

Re-throw the error, prepending the specified message.

public void
pack-priv void
public String
toString()

Overrides java.lang.Throwable.toString.

Print the error with line number and stack trace.

Field Detail

callstackback to summary
pack-priv CallStack callstack
messageback to summary
pack-priv String message
nodeback to summary
pack-priv SimpleNode node

Constructor Detail

EvalErrorback to summary
public EvalError(String s, SimpleNode node, CallStack callstack)

Method Detail

getErrorLineNumberback to summary
public int getErrorLineNumber()
getErrorSourceFileback to summary
public String getErrorSourceFile()
getErrorTextback to summary
public String getErrorText()
getMessageback to summary
public String getMessage()

Overrides java.lang.Throwable.getMessage.

Doc from java.lang.Throwable.getMessage.

Returns the detail message string of this throwable.

Returns:String

the detail message string of this Throwable instance (which may be null).

See Also
for a full display of the information
getNodeback to summary
pack-priv SimpleNode getNode()

The error has trace info associated with it. i.e. It has an AST node that can print its location and source text.

getScriptStackTraceback to summary
public String getScriptStackTrace()
prependMessageback to summary
protected void prependMessage(String s)

Prepend the message if it is non-null.

reThrowback to summary
public void reThrow(String msg) throws EvalError

Re-throw the error, prepending the specified message.

setMessageback to summary
public void setMessage(String s)
setNodeback to summary
pack-priv void setNode(SimpleNode node)
toStringback to summary
public String toString()

Overrides java.lang.Throwable.toString.

Print the error with line number and stack trace.

Returns:String

Doc from java.lang.Throwable.toString.

a string representation of this throwable.