TINMAN 3D / REALTIME TERRAIN
Software Development Kit - User Manual

class SyntaxError in Tinman.Core.Parsing

Describes a syntax error at a specific input position.

sealed class SyntaxError extends ParsingError

Remarks

A syntax error occurs if a grammar rule cannot be matched.

See also:

ParsingErrorType.Syntax

Public / Attributes

ErrorType

The parser error type.

public readonly field ErrorType
type ParsingErrorType
inherited ParsingError.ErrorType

ExpectedTokens

The string tokens that the parser was expecting at the start of Range.

public readonly field ExpectedTokens
type IVectorConst<string>

Remarks:

If no information about expected string tokens is available, this list will be null.

GrammarRule

The grammar rule that contains the rule that has mismatched.

public readonly field GrammarRule
type string

See also:

Grammar.GetRule

MessageContext

The context object.

public property MessageContext { get set }
type object
value The context object or null.
inherited ValidateMessage.MessageContext

MessagePath

The model path that leads to the error source.

public property MessagePath { get set }
type ValidatePath
value The error path (will be None) if no path is available.
inherited ValidateMessage.MessagePath

MessageText

Message that describes this error.

public property MessageText { get }
type string
value [not-null] The error message.
inherited ValidateMessage.MessageText

MessageType

The message type.

public property MessageType { get }
type ValidateMessageType
value The message type.
inherited ValidateMessage.MessageType

Range

Returns source code range of this object.

public property Range { get }
type RangeI
value The source code character range or Inv if none.
inherited ParsingError.Range

Public / Methods

CompareTo

Compares this object with the given one.

[Pure]
public override method CompareTo (IValidateMessage other)
type int32
params other The object to compare to.
returns < 0 : if this object is less than other,
= 0 : if this object is equal to other,
> 0 : if this object is greater than other.
inherited ParsingError.CompareTo

Equals

Compares this object with the given one.

[Pure]
public override method Equals (IValidateMessage other)
type bool
params other The object to compare to.
returns true if this object is equal to other, false if not.
overrides ParsingError.Equals

MismatchedRule

A grammar rule cannot be matched, leading to a syntax error.

public static method MismatchedRule (int32 inputPosition, IGrammarRule rule)
type SyntaxError
params inputPosition Input position of syntax error.
  rule [not-null] The grammar rule that has mismatched.
returns [not-null] The error object.

Throw

public method Throw (string source)
type ValidatingException
params source
inherited ValidateMessage.Throw

Wraps this error object in an exception.

public method Throw (string source, ICodeInput input)
type ValidatingException
params source Error source tag (see ErrorSource).
  input [not-null] The input source code (for error reporting).
returns The ready-to-throw exception.
inherited ParsingError.Throw

ToString

[Pure]
public override sealed method ToString ()
type string
inherited ValidateMessage.ToString

public override method ToString (IValidateMessage previous)
type string
params previous
inherited ParsingError.ToString