MrKWatkins.Ast Help

Listener<TContext, TBaseNode, TNode> Class

Definition

A Listener<TContext, TNode> that only listens to nodes of a specific type. All other nodes will be ignored. The listener will still proceed to descendents of nodes that aren't listened too, i.e. the entire tree will be walked.

public abstract class Listener<TContext, TBaseNode, TNode> : Listener<TContext, TBaseNode> where TBaseNode : Node<TBaseNode> where TNode : TBaseNode

Type Parameters

Name

Description

TContext

The type of the context object.

TBaseNode

The base type of all nodes in the tree.

TNode

The type of the nodes to listen to.

Constructors

Name

Description

Listener()

Methods

Name

Description

AfterListenToNode(TContext, TBaseNode)

AfterListenToNode(TContext, TNode)

Called after a node and its descendents have been listened to.

BeforeListenToNode(TContext, TBaseNode)

BeforeListenToNode(TContext, TNode)

Called before a node and its descendents are listened to.

ListenToNode(TContext, TBaseNode)

ListenToNode(TContext, TNode)

Called when the node is listened to.

Last modified: 22 November 2024