PatternSearch LazyFSM TToken  Method (IEnumerable TToken , Boolean,  LazyFSMPredicate TToken  )NFX Class Library

[This is preliminary documentation and is subject to change.]

Makes finite state machine fed from IEnumerable(Token)

Namespace: NFX.CodeAnalysis
Assembly: NFX (in NFX.dll) Version: 3.0.0.1 (3.0.0.1)
Syntax

public static TToken LazyFSM<TToken>(
	this IEnumerable<TToken> tokens,
	bool onlyPrimary,
	params LazyFSMPredicate<TToken>[] predicates
)
where TToken : Token

Parameters

tokens
Type: OnlineSystem.Collections.Generic IEnumerable TToken 
Token enumerable
onlyPrimary
Type: OnlineSystem Boolean
Sets filter to consider only primary language tokens (skip comments, directives, etc.)
predicates
Type:  NFX.CodeAnalysis LazyFSMPredicate TToken  
Predicates that supply machine state transition instructions
Type Parameters

TToken
Concrete language-typed token

Return Value

Type: TToken
Resulting token fetched by FSMI.Take instruction or null

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type OnlineIEnumerable TToken . When you use instance method syntax to call this method, omit the first parameter. For more information, see OnlineExtension Methods (Visual Basic) or OnlineExtension Methods (C# Programming Guide).
See Also