de.upb.swt.mcie.parser
Class ParseException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by de.upb.swt.mcie.parser.ParseException
All Implemented Interfaces:
java.io.Serializable

public class ParseException
extends java.lang.Exception

Represents a parse exception. It has a reference to the offending token, which has information on the location of the parse error and possibly some more information on the type of the parse error.

Author:
Ekkart Kindler, kindler@upb.de
See Also:
Serialized Form

Field Summary
private  Token token
          The token causing the parse error.
 
Constructor Summary
ParseException(Token token)
          Constructs a ParseException for the token.
 
Method Summary
 java.lang.String toString()
          Returns a textual representation of the parse error and the information on the offending token.
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

token

private Token token
The token causing the parse error.

Constructor Detail

ParseException

ParseException(Token token)
Constructs a ParseException for the token.

Parameters:
token - the offending token
Method Detail

toString

public java.lang.String toString()
Returns a textual representation of the parse error and the information on the offending token.

Overrides:
toString in class java.lang.Throwable