Overview   Project   Class   Tree   Deprecated   Index 
Grammatica 1.3 Documentation
FRAMES    NO FRAMES
SUMMARY:  INNER | FIELD | CONSTR | METHOD

PerCederberg.Grammatica.Parser
Class ParseException

Exception
   |
   +--ParseException

   in ParseException.cs

class ParseException
extends Exception

A parse exception.


Inner Classes, Typedefs, and Enums
enum ParseException.ErrorType
          The error type enumeration.
 
Field Summary
 override string Message
          The message property.
 
Constructor Summary
ParseException( ParseException.ErrorType type, string info, int line, int column )
          Creates a new parse exception.
ParseException( ParseException.ErrorType type, string info, ArrayList details, int line, int column )
          Creates a new parse exception.
 
Method Summary
 int GetColumn()
          Returns the column number where the error occured.
 ArrayList GetDetails()
          Returns the additional detailed error information.
 string GetErrorMessage()
          Returns the error message.
 ParseException.ErrorType GetErrorType()
          Returns the error type.
 string GetInfo()
          Returns the additional error information.
 int GetLine()
          Returns the line number where the error occured.
 string GetMessage()
          Returns a default error message.
 

Field Detail

Message

public override string Message;
The message property. This property contains the detailed exception error message.


Constructor Detail

ParseException

public ParseException( ParseException.ErrorType type, string info, int line, int column );
Creates a new parse exception.
Parameters:
type - the parse error type
info - the additional information
line - the line number, or -1 for unknown
column - the column number, or -1 for unknown

ParseException

public ParseException( ParseException.ErrorType type, string info, ArrayList details, int line, int column );
Creates a new parse exception. This constructor is only used to supply the detailed information array, which is only used for expected token errors. The list then contains descriptions of the expected tokens.
Parameters:
type - the parse error type
info - the additional information
details - the additional detailed information
line - the line number, or -1 for unknown
column - the column number, or -1 for unknown


Method Detail

GetColumn

public int GetColumn();
Returns the column number where the error occured.
Returns:
the column number of the error, or -1 if unknown

GetDetails

public ArrayList GetDetails();
Returns the additional detailed error information.
Returns:
the additional detailed error information

GetErrorMessage

public string GetErrorMessage();
Returns the error message. This message will contain all the information available, except for the line and column number information.
Returns:
the error message

GetErrorType

public ParseException.ErrorType GetErrorType();
Returns the error type.
Returns:
the error type

GetInfo

public string GetInfo();
Returns the additional error information.
Returns:
the additional error information

GetLine

public int GetLine();
Returns the line number where the error occured.
Returns:
the line number of the error, or -1 if unknown

GetMessage

public string GetMessage();
Returns a default error message.
Returns:
a default error message

 Overview   Project   Class   Tree   Deprecated   Index 
Grammatica 1.3 Documentation
FRAMES    NO FRAMES
SUMMARY:  INNER | FIELD | CONSTR | METHOD