19 instantiations of TransformNode
Microsoft.CodeAnalysis (8)
SourceGeneration\Nodes\TransformNode.cs (2)
37
=> new
TransformNode
<TInput, TOutput>(_sourceNode, _func, comparer, _name);
40
=> new
TransformNode
<TInput, TOutput>(_sourceNode, _func, _comparer, name);
SourceGeneration\Nodes\ValueSourceExtensions.cs (6)
16
public static IncrementalValueProvider<TResult> Select<TSource, TResult>(this IncrementalValueProvider<TSource> source, Func<TSource, CancellationToken, TResult> selector) => new IncrementalValueProvider<TResult>(new
TransformNode
<TSource, TResult>(source.Node, selector.WrapUserFunction()));
18
public static IncrementalValuesProvider<TResult> Select<TSource, TResult>(this IncrementalValuesProvider<TSource> source, Func<TSource, CancellationToken, TResult> selector) => new IncrementalValuesProvider<TResult>(new
TransformNode
<TSource, TResult>(source.Node, selector.WrapUserFunction()));
21
public static IncrementalValuesProvider<TResult> SelectMany<TSource, TResult>(this IncrementalValueProvider<TSource> source, Func<TSource, CancellationToken, ImmutableArray<TResult>> selector) => new IncrementalValuesProvider<TResult>(new
TransformNode
<TSource, TResult>(source.Node, selector.WrapUserFunction()));
23
public static IncrementalValuesProvider<TResult> SelectMany<TSource, TResult>(this IncrementalValueProvider<TSource> source, Func<TSource, CancellationToken, IEnumerable<TResult>> selector) => new IncrementalValuesProvider<TResult>(new
TransformNode
<TSource, TResult>(source.Node, selector.WrapUserFunctionAsImmutableArray()));
25
public static IncrementalValuesProvider<TResult> SelectMany<TSource, TResult>(this IncrementalValuesProvider<TSource> source, Func<TSource, CancellationToken, ImmutableArray<TResult>> selector) => new IncrementalValuesProvider<TResult>(new
TransformNode
<TSource, TResult>(source.Node, selector.WrapUserFunction()));
27
public static IncrementalValuesProvider<TResult> SelectMany<TSource, TResult>(this IncrementalValuesProvider<TSource> source, Func<TSource, CancellationToken, IEnumerable<TResult>> selector) => new IncrementalValuesProvider<TResult>(new
TransformNode
<TSource, TResult>(source.Node, selector.WrapUserFunctionAsImmutableArray()));
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (11)
SourceGeneration\StateTableTests.cs (11)
593
TransformNode<int, int> transformNode = new
TransformNode
<int, int>(inputNode, (i, ct) => i, name: "Transform");
624
TransformNode<int, int> transformNode = new
TransformNode
<int, int>(inputNode, (i, ct) => i, name: "Transform");
660
TransformNode<int, int> transformNode = new
TransformNode
<int, int>(inputNode, (i, ct) => i, name: "Transform");
699
TransformNode<int, int> transformNode = new
TransformNode
<int, int>(inputNode, (i, ct) => transformNodeResult, name: "Transform");
790
var transformNode = new
TransformNode
<int, int>(inputNode, (i, ct) => ImmutableArray.Create(i)).WithTrackingName("TestStep");
900
var transformNode = new
TransformNode
<ImmutableArray<int>, int>(batchNode, (arr, ct) => arr, name: "Transform");
901
var filterNode = new
TransformNode
<int, int>(transformNode, (i, ct) => i <= 2 ? ImmutableArray.Create(i) : ImmutableArray<int>.Empty, name: "Filter");
902
var doubleNode = new
TransformNode
<int, int>(filterNode, (i, ct) => i * 2, name: "Double");
903
var addOneNode = new
TransformNode
<int, int>(doubleNode, (i, ct) => i + 1, name: "AddOne");
933
var transformNode = new
TransformNode
<ImmutableArray<int>, int>(inputNode, (arr, ct) => arr, name: "SelectMany");
962
var transformNode = new
TransformNode
<ImmutableArray<int>, int>(inputNode, (arr, ct) => arr, name: "SelectMany");
10 references to TransformNode
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (10)
SourceGeneration\StateTableTests.cs (10)
593
TransformNode
<int, int> transformNode = new TransformNode<int, int>(inputNode, (i, ct) => i, name: "Transform");
624
TransformNode
<int, int> transformNode = new TransformNode<int, int>(inputNode, (i, ct) => i, name: "Transform");
660
TransformNode
<int, int> transformNode = new TransformNode<int, int>(inputNode, (i, ct) => i, name: "Transform");
699
TransformNode
<int, int> transformNode = new TransformNode<int, int>(inputNode, (i, ct) => transformNodeResult, name: "Transform");
900
var
transformNode = new TransformNode<ImmutableArray<int>, int>(batchNode, (arr, ct) => arr, name: "Transform");
901
var
filterNode = new TransformNode<int, int>(transformNode, (i, ct) => i <= 2 ? ImmutableArray.Create(i) : ImmutableArray<int>.Empty, name: "Filter");
902
var
doubleNode = new TransformNode<int, int>(filterNode, (i, ct) => i * 2, name: "Double");
903
var
addOneNode = new TransformNode<int, int>(doubleNode, (i, ct) => i + 1, name: "AddOne");
933
var
transformNode = new TransformNode<ImmutableArray<int>, int>(inputNode, (arr, ct) => arr, name: "SelectMany");
962
var
transformNode = new TransformNode<ImmutableArray<int>, int>(inputNode, (arr, ct) => arr, name: "SelectMany");