org.apache.beehive.netui.script
Class ExpressionEvaluationException

Object
  extended by Throwable
      extended by Exception
          extended by ExpressionEvaluationException
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
ExpressionUpdateException

public class ExpressionEvaluationException
extends Exception

An exception thrown when errors occur evaluating an expression.

See Also:
Serialized Form

Constructor Summary
ExpressionEvaluationException()
          Construct an ExpressionEvaluationException.
ExpressionEvaluationException(String message, String expression)
          Construct an ExpressionEvaluationException with the given message and the failed expression.
ExpressionEvaluationException(String message, String expression, Throwable cause)
          Construct an ExpressionEvaluationException with the given message, the failed expression, and cause.
ExpressionEvaluationException(String expression, Throwable cause)
          Construct a ExpressionEvaluationException with the given message and cause.
 
Method Summary
 String[] getAvailableContexts()
          Get the top-level contexts that were available at the time that the expression failed.
 String getExpression()
          Get the expression whose failed evaluation cause this exception to be thrown.
 String getLocalizedMessage()
           
 void setAvailableContexts(String[] contexts)
          Set the set of top-level contexts that were available at the time that the expression failed.
 void setLocalizedMessage(String localizedMessage)
           
 
Methods inherited from class Throwable
fillInStackTrace, getCause, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ExpressionEvaluationException

public ExpressionEvaluationException()
Construct an ExpressionEvaluationException.


ExpressionEvaluationException

public ExpressionEvaluationException(String message,
                                     String expression)
Construct an ExpressionEvaluationException with the given message and the failed expression.

Parameters:
message - a String containing the text of the exception message
expression - the expression whose evaluation failed

ExpressionEvaluationException

public ExpressionEvaluationException(String message,
                                     String expression,
                                     Throwable cause)
Construct an ExpressionEvaluationException with the given message, the failed expression, and cause.

Parameters:
message - a String containing the text of the exception message
expression - the expression whose evaluation failed
cause - a Throwable that is wrapped by this exception

ExpressionEvaluationException

public ExpressionEvaluationException(String expression,
                                     Throwable cause)
Construct a ExpressionEvaluationException with the given message and cause.

Parameters:
expression - a String containing the text of the exception message
cause - a Throwable that is wrapped by this exception
Method Detail

getExpression

public String getExpression()
Get the expression whose failed evaluation cause this exception to be thrown.

Returns:
the expression that caused the problem

setAvailableContexts

public void setAvailableContexts(String[] contexts)
Set the set of top-level contexts that were available at the time that the expression failed.

Parameters:
contexts - the list of available contexts.

getAvailableContexts

public String[] getAvailableContexts()
Get the top-level contexts that were available at the time that the expression failed.

Returns:
the contexts that were available at the time the expression was evaluated or null if the contexts were not set.

setLocalizedMessage

public void setLocalizedMessage(String localizedMessage)

getLocalizedMessage

public String getLocalizedMessage()
Overrides:
getLocalizedMessage in class Throwable