1 instantiation of ApiLine
Microsoft.CodeAnalysis.PublicApiAnalyzers (1)
DeclarePublicApiAnalyzer.cs (1)
182var apiLine = new ApiLine(text, line.Span, additionalFileInfo);
24 references to ApiLine
Microsoft.CodeAnalysis.PublicApiAnalyzers (24)
DeclarePublicApiAnalyzer.cs (8)
158var apiBuilder = ArrayBuilder<ApiLine>.GetInstance(); 182var apiLine = new ApiLine(text, line.Span, additionalFileInfo); 253var apiBuilder = ArrayBuilder<ApiLine>.GetInstance(); 383var publicApiMap = PooledDictionary<string, ApiLine>.GetInstance(StringComparer.Ordinal); 391private static void ValidateApiList(ImmutableDictionary<AdditionalText, SourceText> additionalFiles, Dictionary<string, ApiLine> publicApiMap, ImmutableArray<ApiLine> apiList, bool isPublic, List<Diagnostic> errors) 393foreach (ApiLine cur in apiList) 396if (publicApiMap.TryGetValue(textWithoutOblivious, out ApiLine existingLine))
DeclarePublicApiAnalyzer.Impl.cs (16)
58private readonly record struct RemovedApiLine(string Text, ApiLine ApiLine); 63private sealed record ApiData(ImmutableArray<ApiLine> ApiList, ImmutableArray<RemovedApiLine> RemovedApiList, int NullableLineNumber) 65public static readonly ApiData Empty = new(ImmutableArray<ApiLine>.Empty, ImmutableArray<RemovedApiLine>.Empty, NullableLineNumber: -1); 85private readonly Lazy<IReadOnlyDictionary<string, ApiLine>> _apiMap; 95_apiMap = new Lazy<IReadOnlyDictionary<string, ApiLine>>(() => CreateApiMap(shippedData, unshippedData)); 99static IReadOnlyDictionary<string, ApiLine> CreateApiMap(ApiData shippedData, ApiData unshippedData) 103var publicApiMap = new Dictionary<string, ApiLine>(shippedData.ApiList.Length + unshippedData.ApiList.Length, StringComparer.Ordinal); 104foreach (ApiLine cur in shippedData.ApiList) 109foreach (ApiLine cur in unshippedData.ApiList) 237IReadOnlyDictionary<string, ApiLine> apiMap = _apiMap.Value; 249ApiLine foundApiLine; 376var isOverloadUnshipped = !lookupPublicApi(overloadPublicApiName, out ApiLine overloadPublicApiLine) || 450bool lookupPublicApi(ApiName overloadPublicApiName, out ApiLine overloadPublicApiLine) 518foreach (var apiLine in _unshippedData.ApiList) 751IReadOnlyDictionary<string, ApiLine> apiMap = _apiMap.Value; 752foreach (KeyValuePair<string, ApiLine> pair in apiMap)