Grammatica
Public Types | Public Member Functions | Properties | List of all members
PerCederberg.Grammatica.Runtime.RE.RegExpException Class Reference

A regular expression exception. More...

Inheritance diagram for PerCederberg.Grammatica.Runtime.RE.RegExpException:

Public Types

enum  ErrorType {
  ErrorType.UNEXPECTED_CHARACTER, ErrorType.UNTERMINATED_PATTERN, ErrorType.UNSUPPORTED_SPECIAL_CHARACTER, ErrorType.UNSUPPORTED_ESCAPE_CHARACTER,
  ErrorType.INVALID_REPEAT_COUNT
}
 The error type enumeration. More...
 

Public Member Functions

 RegExpException (ErrorType type, int pos, string pattern)
 Creates a new regular expression exception. More...
 
string GetMessage ()
 Returns the exception error message. More...
 

Properties

override string Message [get]
 The message property. More...
 

Detailed Description

A regular expression exception.

This exception is thrown if a regular expression couldn't be processed (or "compiled") properly.

Author
Per Cederberg
Version
1.0

Member Enumeration Documentation

The error type enumeration.

Enumerator
UNEXPECTED_CHARACTER 

The unexpected character error constant.

This error is used when a character was read that didn't match the allowed set of characters at the given position.

UNTERMINATED_PATTERN 

The unterminated pattern error constant.

This error is used when more characters were expected in the pattern.

UNSUPPORTED_SPECIAL_CHARACTER 

The unsupported special character error constant.

This error is used when special regular expression characters are used in the pattern, but not supported in this implementation.

UNSUPPORTED_ESCAPE_CHARACTER 

The unsupported escape character error constant.

This error is used when an escape character construct is used in the pattern, but not supported in this implementation.

INVALID_REPEAT_COUNT 

The invalid repeat count error constant.

This error is used when a repetition count of zero is specified, or when the minimum exceeds the maximum.

Constructor & Destructor Documentation

PerCederberg.Grammatica.Runtime.RE.RegExpException.RegExpException ( ErrorType  type,
int  pos,
string  pattern 
)
inline

Creates a new regular expression exception.

Parameters
typethe error type constant
posthe error position
patternthe regular expression pattern

Member Function Documentation

string PerCederberg.Grammatica.Runtime.RE.RegExpException.GetMessage ( )
inline

Returns the exception error message.

Returns
the exception error message

Property Documentation

override string PerCederberg.Grammatica.Runtime.RE.RegExpException.Message
get

The message property.

This property contains the detailed exception error message.


The documentation for this class was generated from the following file: