Sawmill

Class RewriterBuilderCase<TArgs, TBase, TSub>

Tools for building rewriters for a single subclass of a base type.

Inheritance
  • Object
  • RewriterBuilderCase<TArgs, TBase, TSub>
Declaration
public sealed class RewriterBuilderCase<TArgs, TBase, TSub> : Object
Type Parameters
Name Description

TArgs

TBase

TSub

Methods

Child(Func<TSub, TBase>)

Select an immediate child

Declaration
public RewriterBuilderCase<ValueTuple<TArgs, TBase>, TBase, TSub> Child(Func<TSub, TBase> child)
Parameters
Type Name Description

Func<TSub, TBase>

child

Returns
Type Description

RewriterBuilderCase<ValueTuple<TArgs, TBase>, TBase, TSub>

Children(Func<TSub, ImmutableList<TBase>>)

Select a list of children.

Declaration
public RewriterBuilderCase<ValueTuple<TArgs, ImmutableList<TBase>>, TBase, TSub> Children(Func<TSub, ImmutableList<TBase>> children)
Parameters
Type Name Description

Func<TSub, ImmutableList<TBase>>

children

Returns
Type Description

RewriterBuilderCase<ValueTuple<TArgs, ImmutableList<TBase>>, TBase, TSub>

Field<U>(Func<TSub, U>)

Select a field from the subclass

Declaration
public RewriterBuilderCase<ValueTuple<TArgs, U>, TBase, TSub> Field<U>(Func<TSub, U> field)
Parameters
Type Name Description

Func<TSub, U>

field

Returns
Type Description

RewriterBuilderCase<ValueTuple<TArgs, U>, TBase, TSub>

Type Parameters
Name Description

U