Sawmill

Class ExpressionRewriter

An implementation of IRewriter<T> for Expressions.

Inheritance
Implements
Declaration
public class ExpressionRewriter : Object, IRewriter<Expression>

Constructors

ExpressionRewriter()

Create a new instance of ExpressionRewriter

Declaration
protected ExpressionRewriter()

Properties

Instance

Gets the single global instance of ExpressionRewriter.

Declaration
public static ExpressionRewriter Instance { get; }
Property Value
Type Description

ExpressionRewriter

The single global instance of ExpressionRewriter.

Methods

CountChildren(Expression)

CountChildren(T)
Declaration
public int CountChildren(Expression value)
Parameters
Type Name Description

Expression

value

Returns
Type Description

Int32

GetChildren(Span<Expression>, Expression)

GetChildren(Span<T>, T)
Declaration
public void GetChildren(Span<Expression> children, Expression value)
Parameters
Type Name Description

Span<Expression>

children

Expression

value

SetChildren(ReadOnlySpan<Expression>, Expression)

SetChildren(ReadOnlySpan<T>, T)
Declaration
public Expression SetChildren(ReadOnlySpan<Expression> newChildren, Expression oldValue)
Parameters
Type Name Description

ReadOnlySpan<Expression>

newChildren

Expression

oldValue

Returns
Type Description

Expression

Implements

IRewriter<T>