org.mozilla.javascript
Class EvaluatorException

java.lang.Object
  |
  +--java.lang.Throwable
        |
        +--java.lang.Exception
              |
              +--java.lang.RuntimeException
                    |
                    +--org.mozilla.javascript.EvaluatorException
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
WrappedException

public class EvaluatorException
extends java.lang.RuntimeException

The class of exceptions thrown by the JavaScript engine.

See Also:
Serialized Form

Constructor Summary
EvaluatorException(java.lang.String detail)
          Create an exception with the specified detail message.
EvaluatorException(java.lang.String detail, java.lang.String sourceName, int lineNumber, java.lang.String lineSource, int columnNumber)
          Create an exception with the specified detail message.
 
Method Summary
 int getColumnNumber()
          The column number of the location of the error, or zero if unknown.
 int getLineNumber()
          Returns the line number of the statement causing the error, or zero if not available.
 java.lang.String getLineSource()
          The source of the line causing the error, or zero if unknown.
 java.lang.String getSourceName()
          Get the name of the source containing the error, or null if that information is not available.
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getLocalizedMessage, getMessage, printStackTrace, printStackTrace, printStackTrace, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

EvaluatorException

public EvaluatorException(java.lang.String detail)
Create an exception with the specified detail message. Errors internal to the JavaScript engine will simply throw a RuntimeException.
Parameters:
detail - a message with detail about the exception

EvaluatorException

public EvaluatorException(java.lang.String detail,
                          java.lang.String sourceName,
                          int lineNumber,
                          java.lang.String lineSource,
                          int columnNumber)
Create an exception with the specified detail message. Errors internal to the JavaScript engine will simply throw a RuntimeException.
Parameters:
detail - the error message
sourceName - the name of the source reponsible for the error
lineNumber - the line number of the source
columnNumber - the columnNumber of the source (may be zero if unknown)
lineSource - the source of the line containing the error (may be null if unknown)
Method Detail

getSourceName

public java.lang.String getSourceName()
Get the name of the source containing the error, or null if that information is not available.

getLineNumber

public int getLineNumber()
Returns the line number of the statement causing the error, or zero if not available.

getColumnNumber

public int getColumnNumber()
The column number of the location of the error, or zero if unknown.

getLineSource

public java.lang.String getLineSource()
The source of the line causing the error, or zero if unknown.