1 implementation of IStateTable
Microsoft.CodeAnalysis (1)
SourceGeneration\Nodes\NodeStateTable.cs (1)
61
internal sealed class NodeStateTable<T> :
IStateTable
17 references to IStateTable
Microsoft.CodeAnalysis (17)
SourceGeneration\Nodes\DriverStateTable.cs (1)
51
if (_stateTableBuilder.TryGetTable(source, out
var
table))
SourceGeneration\Nodes\GeneratorRunStateTable.cs (1)
39
public void RecordStepsFromOutputNodeUpdate(
IStateTable
table)
SourceGeneration\Nodes\NodeStateTable.cs (3)
49
IStateTable
AsCached();
128
IStateTable
IStateTable
.AsCached() => AsCached();
SourceGeneration\Nodes\StateTableStore.cs (9)
16
private readonly ImmutableSegmentedDictionary<object,
IStateTable
> _tables;
18
public static readonly StateTableStore Empty = new StateTableStore(ImmutableSegmentedDictionary<object,
IStateTable
>.Empty);
20
private StateTableStore(ImmutableSegmentedDictionary<object,
IStateTable
> tables)
25
public bool TryGetValue(object key, [NotNullWhen(true)] out
IStateTable
? table) => _tables.TryGetValue(key, out table);
34
if (TryGetValue(input, out
var
output))
43
private readonly ImmutableSegmentedDictionary<object,
IStateTable
>.Builder _tableBuilder = ImmutableSegmentedDictionary.CreateBuilder<object,
IStateTable
>();
47
public bool TryGetTable(object key, [NotNullWhen(true)] out
IStateTable
? table) => _tableBuilder.TryGetValue(key, out table);
49
public void SetTable(object key,
IStateTable
table) => _tableBuilder[key] = table;
SourceGeneration\SyntaxStore.cs (3)
49
public
IStateTable
GetSyntaxInputTable(SyntaxInputNode syntaxInputNode, NodeStateTable<SyntaxTree> syntaxTreeTable)
67
if (compilationIsCached && !_enableTracking && _previous._tables.TryGetValue(node, out
var
previousStateTable))
137
if (!_tableBuilder.TryGetTable(syntaxInputNode, out
var
result))