4 instantiations of SymbolTreeInfo
Microsoft.CodeAnalysis.Workspaces (4)
FindSymbols\SymbolTree\SymbolTreeInfo.cs (3)
105
return new
SymbolTreeInfo
(checksum, sortedNodes,
115
return new
SymbolTreeInfo
(
466
return new
SymbolTreeInfo
(
FindSymbols\SymbolTree\SymbolTreeInfo_Serialization.cs (1)
261
return new
SymbolTreeInfo
(
96 references to SymbolTreeInfo
Microsoft.CodeAnalysis.EditorFeatures.UnitTests (24)
FindSymbols\SymbolTreeInfoTests.cs (24)
27
var
info1 = await
SymbolTreeInfo
.GetInfoForMetadataReferenceAsync(
30
var
info2 = await
SymbolTreeInfo
.GetInfoForMetadataReferenceAsync(
34
Assert.Equal(info1.Checksum,
SymbolTreeInfo
.GetMetadataChecksum(solution.Services, reference1, CancellationToken.None));
35
Assert.Equal(info2.Checksum,
SymbolTreeInfo
.GetMetadataChecksum(solution.Services, reference2, CancellationToken.None));
48
var checksum1 =
SymbolTreeInfo
.GetMetadataChecksum(solution.Services, reference1, CancellationToken.None);
49
var
info1 = await
SymbolTreeInfo
.GetInfoForMetadataReferenceAsync(
52
var checksum2 =
SymbolTreeInfo
.GetMetadataChecksum(solution.Services, reference2, CancellationToken.None);
53
var
info2 = await
SymbolTreeInfo
.GetInfoForMetadataReferenceAsync(
71
var checksum1 =
SymbolTreeInfo
.GetMetadataChecksum(solution.Services, reference1, CancellationToken.None);
72
var
info1 = await
SymbolTreeInfo
.GetInfoForMetadataReferenceAsync(
75
var
info2 = await
SymbolTreeInfo
.GetInfoForMetadataReferenceAsync(
80
Assert.Equal(info2.Checksum,
SymbolTreeInfo
.GetMetadataChecksum(solution.Services, reference2, CancellationToken.None));
93
var
info1 = await
SymbolTreeInfo
.GetInfoForMetadataReferenceAsync(
96
var checksum2 =
SymbolTreeInfo
.GetMetadataChecksum(solution.Services, reference2, CancellationToken.None);
97
var
info2 = await
SymbolTreeInfo
.GetInfoForMetadataReferenceAsync(
101
Assert.Equal(info1.Checksum,
SymbolTreeInfo
.GetMetadataChecksum(solution.Services, reference1, CancellationToken.None));
Microsoft.CodeAnalysis.Features (12)
AddImport\SearchScopes\MetadataSymbolsSearchScope.cs (1)
39
var
info = await service.TryGetPotentiallyStaleMetadataSymbolTreeInfoAsync(_assemblyProject, _metadataReference, cancellationToken).ConfigureAwait(false);
AddImport\SearchScopes\SourceSymbolsProjectSearchScope.cs (1)
33
var
info = await service.TryGetPotentiallyStaleSourceSymbolTreeInfoAsync(_project, cancellationToken).ConfigureAwait(false);
Completion\Providers\ImportCompletionProvider\AbstractTypeImportCompletionService.cs (2)
180
var checksum = await
SymbolTreeInfo
.GetSourceSymbolsChecksumAsync(project, cancellationToken).ConfigureAwait(false);
215
checksum:
SymbolTreeInfo
.GetMetadataChecksum(solution.Services, peReference, cancellationToken),
Completion\Providers\ImportCompletionProvider\ExtensionMethodImportCompletionHelper.cs (1)
240
var checksum = await
SymbolTreeInfo
.GetSourceSymbolsChecksumAsync(project, cancellationToken).ConfigureAwait(false);
Completion\Providers\ImportCompletionProvider\ExtensionMethodImportCompletionHelper.SymbolComputer.cs (5)
78
await
SymbolTreeInfo
.GetInfoForMetadataReferenceAsync(project.Solution, peReference, checksum: null, cancellationToken).ConfigureAwait(false);
186
SymbolTreeInfo
? symbolInfo;
189
symbolInfo = await
SymbolTreeInfo
.GetInfoForMetadataReferenceAsync(
194
var cachedInfoTask =
SymbolTreeInfo
.TryGetCachedInfoForMetadataReferenceIgnoreChecksumAsync(peReference, cancellationToken);
455
private MultiDictionary<string, (string methodName, string receiverTypeName)> CreateAggregatedFilter(
SymbolTreeInfo
symbolInfo)
DesignerAttribute\DesignerAttributeDiscoveryService.cs (2)
109
var
info = await
SymbolTreeInfo
.GetInfoForMetadataReferenceAsync(
Microsoft.CodeAnalysis.Workspaces (56)
FindSymbols\Declarations\DeclarationFinder.cs (2)
82
var
info = await
SymbolTreeInfo
.GetInfoForMetadataReferenceAsync(
FindSymbols\FindReferences\DependentProjectsFinder.cs (1)
340
var metadataId =
SymbolTreeInfo
.GetMetadataIdNoThrow(peReference);
FindSymbols\FindReferences\DependentTypeFinder.cs (2)
345
var
symbolTreeInfo = await
SymbolTreeInfo
.GetInfoForMetadataReferenceAsync(
FindSymbols\SymbolTree\ISymbolTreeInfoCacheService.cs (3)
12
/// Computes and caches <see cref="
SymbolTreeInfo
"/> indices for the source symbols in <see cref="Project"/>s and
17
ValueTask<
SymbolTreeInfo
?> TryGetPotentiallyStaleSourceSymbolTreeInfoAsync(Project project, CancellationToken cancellationToken);
18
ValueTask<
SymbolTreeInfo
?> TryGetPotentiallyStaleMetadataSymbolTreeInfoAsync(Project project, PortableExecutableReference reference, CancellationToken cancellationToken);
FindSymbols\SymbolTree\MetadataInfo.cs (2)
17
public readonly
SymbolTreeInfo
SymbolTreeInfo;
28
public MetadataInfo(
SymbolTreeInfo
info, HashSet<ProjectId> referencingProjects)
FindSymbols\SymbolTree\SymbolTreeInfo.cs (4)
100
public static
SymbolTreeInfo
CreateEmpty(Checksum checksum)
110
public
SymbolTreeInfo
WithChecksum(Checksum checksum)
432
internal void AssertEquivalentTo(
SymbolTreeInfo
other)
458
private static
SymbolTreeInfo
CreateSymbolTreeInfo(
FindSymbols\SymbolTree\SymbolTreeInfo.Node.cs (1)
20
/// produce the final <see cref="
SymbolTreeInfo
"/> though we will then convert
FindSymbols\SymbolTree\SymbolTreeInfo_Metadata.cs (17)
40
private static readonly ConditionalWeakTable<PortableExecutableReference, AsyncLazy<
SymbolTreeInfo
>> s_peReferenceToInfo = new();
49
/// computation of the <see cref="
SymbolTreeInfo
"/> once per <see cref="MetadataId"/>, but we may then have to
52
private static readonly ConditionalWeakTable<MetadataId, AsyncLazy<
SymbolTreeInfo
>> s_metadataIdToSymbolTreeInfo = new();
95
/// Produces a <see cref="
SymbolTreeInfo
"/> for a given <see cref="PortableExecutableReference"/>.
100
/// and used for the <see cref="
SymbolTreeInfo
"/>.</param>
102
public static ValueTask<
SymbolTreeInfo
> GetInfoForMetadataReferenceAsync(
117
/// Produces a <see cref="
SymbolTreeInfo
"/> for a given <see cref="PortableExecutableReference"/>.
122
/// and used for the <see cref="
SymbolTreeInfo
"/>.</param>
124
public static async ValueTask<
SymbolTreeInfo
> GetInfoForMetadataReferenceAsync(
135
var
info = await infoTask.GetValueAsync(cancellationToken).ConfigureAwait(false);
143
static async Task<
SymbolTreeInfo
> GetInfoForMetadataReferenceSlowAsync(
168
static async Task<
SymbolTreeInfo
> CreateMetadataSymbolTreeInfoAsync(
186
createAsync: checksum => new ValueTask<
SymbolTreeInfo
>(new MetadataInfoCreator(checksum, GetMetadataNoThrow(arg.reference)).Create()),
191
var
metadataIdSymbolTreeInfo = await asyncLazy.GetValueAsync(cancellationToken).ConfigureAwait(false);
201
public static async Task<
SymbolTreeInfo
?> TryGetCachedInfoForMetadataReferenceIgnoreChecksumAsync(PortableExecutableReference reference, CancellationToken cancellationToken)
236
public static Task<
SymbolTreeInfo
?> LoadAnyInfoForMetadataReferenceAsync(
295
internal
SymbolTreeInfo
Create()
FindSymbols\SymbolTree\SymbolTreeInfo_Serialization.cs (7)
28
private static async Task<
SymbolTreeInfo
> LoadOrCreateAsync(
32
Func<Checksum, ValueTask<
SymbolTreeInfo
>> createAsync,
41
var
read = await LoadAsync(services, solutionKey, checksum, checksumMustMatch: true, keySuffix, cancellationToken).ConfigureAwait(false);
53
SymbolTreeInfo
result;
81
private static async Task<
SymbolTreeInfo
?> LoadAsync(
191
private static
SymbolTreeInfo
? TryReadSymbolTreeInfo(
274
public static
SymbolTreeInfo
? ReadSymbolTreeInfo(ObjectReader reader, Checksum checksum)
FindSymbols\SymbolTree\SymbolTreeInfo_Source.cs (3)
34
public static Task<
SymbolTreeInfo
> GetInfoForSourceAssemblyAsync(
53
public static async Task<
SymbolTreeInfo
?> LoadAnyInfoForSourceAssemblyAsync(
119
internal static async ValueTask<
SymbolTreeInfo
> CreateSourceSymbolTreeInfoAsync(
FindSymbols\SymbolTree\SymbolTreeInfoCacheService.cs (14)
30
private readonly ConcurrentDictionary<ProjectId, (VersionStamp semanticVersion,
SymbolTreeInfo
info)> _projectIdToInfo = [];
64
/// Gets the latest computed <see cref="
SymbolTreeInfo
"/> for the requested <paramref name="reference"/>.
68
public async ValueTask<
SymbolTreeInfo
?> TryGetPotentiallyStaleMetadataSymbolTreeInfoAsync(
85
var
info = await
SymbolTreeInfo
.LoadAnyInfoForMetadataReferenceAsync(solution, reference, cancellationToken).ConfigureAwait(false);
95
public async ValueTask<
SymbolTreeInfo
?> TryGetPotentiallyStaleSourceSymbolTreeInfoAsync(
109
var
info = await
SymbolTreeInfo
.LoadAnyInfoForSourceAssemblyAsync(project, cancellationToken).ConfigureAwait(false);
173
var checksum = await
SymbolTreeInfo
.GetSourceSymbolsChecksumAsync(project, cancellationToken).ConfigureAwait(false);
177
var
info = await
SymbolTreeInfo
.GetInfoForSourceAssemblyAsync(
195
var checksum =
SymbolTreeInfo
.GetMetadataChecksum(project.Solution.Services, reference, cancellationToken);
199
var
info = await
SymbolTreeInfo
.GetInfoForMetadataReferenceAsync(
Microsoft.CodeAnalysis.Workspaces.UnitTests (4)
FindAllDeclarationsTests.cs (4)
628
var
info = await
SymbolTreeInfo
.CreateSourceSymbolTreeInfoAsync(
639
var
readInfo =
SymbolTreeInfo
.TestAccessor.ReadSymbolTreeInfo(reader, Checksum.Null);