expression

< Back


IExpressionFactory<T>

Namespace: Albatross.Expression.Parsing

Factory interface for parsing tokens from expression text.

public interface IExpressionFactory<T>

Type Parameters

T
The type of token this factory produces.

Attributes NullableContextAttribute

Methods

Parse(String, Int32, Int32&)

Attempts to parse a token from the given text starting at the specified position.

T Parse(string text, int start, Int32& next)

Parameters

text String
The expression text to parse.

start Int32
The starting position in the text to begin parsing.

next Int32&
When this method returns, contains the position after the parsed token, or the original start position if parsing failed.

Returns

T
The parsed token if successful; otherwise, null.


< Back