5 implementations of
System.Linq (2)
System\Linq\Lookup.cs (2)
140public IEnumerable<TElement> this[TKey key] => GetGrouping(key, create: false) ?? Enumerable.Empty<TElement>(); 324public IEnumerable<TElement> this[TKey key] => [];
System.Linq.AsyncEnumerable (2)
System\Linq\ToLookupAsync.cs (2)
228public IEnumerable<TElement> this[TKey key] => []; 331public IEnumerable<TElement> this[TKey key] => GetGrouping(key, create: false) ?? Enumerable.Empty<TElement>();
System.Linq.Parallel (1)
System\Linq\Parallel\Utils\Lookup.cs (1)
64public IEnumerable<TElement> this[TKey key]
60 references to
Aspire.Dashboard (20)
Otlp\Storage\SqliteTelemetryRepository.Caching.cs (1)
572scopeAttributes[record.ScopeId]
Otlp\Storage\SqliteTelemetryRepository.Logs.cs (1)
711ToPairs(logAttributes[record.LogId]),
Otlp\Storage\SqliteTelemetryRepository.Metrics.Reads.cs (9)
241foreach (var point in points[dimensionId]) 254value.Exemplars.AddRange(exemplars[point.PointId]); 289hasOverflow = dimensionIds.Any(dimensionId => IsOverflowDimension(pointAttributes[dimensionId])); 296.SelectMany(dimensionId => pointAttributes[dimensionId] 309.Where(dimensionId => MatchesDimensionFilters(attributes[dimensionId], dimensionFilters)) 314attributes[dimensionId].Select(attribute => KeyValuePair.Create(attribute.AttributeKey, attribute.AttributeValue)).ToArray()))) 374foreach (var key in knownAttributeValues.Keys.Union(attributes[dimensionId].Select(attribute => attribute.AttributeKey)).Distinct().ToList()) 385var value = attributes[dimensionId].FirstOrDefault(attribute => attribute.AttributeKey == key)?.AttributeValue; 463Attributes = attributes[item.Record.ExemplarId].Select(attribute => KeyValuePair.Create(attribute.AttributeKey, attribute.AttributeValue)).ToArray()
Otlp\Storage\SqliteTelemetryRepository.Traces.Reads.cs (2)
813Attributes = ToPairs(eventAttributes[spanEvent.EventId]) 830Attributes = ToPairs(linkAttributes[link.LinkId])
ServiceClient\SqliteResourceRepository.Storage.cs (7)
451foreach (var environment in environments[record.ResourceName]) 460foreach (var url in urls[record.ResourceName]) 475resource.Volumes.Add(volumes[record.ResourceName].Select(volume => new Volume 482foreach (var healthReport in healthReports[record.ResourceName]) 495resource.Relationships.Add(relationships[record.ResourceName].Select(relationship => new ResourceRelationship 500foreach (var property in properties[record.ResourceName]) 524foreach (var commandRecord in commands[record.ResourceName])
Aspire.Hosting (4)
Devcontainers\DevcontainerSettingsWriter.cs (1)
161foreach (var oldPort in portsByLabel[label])
Orchestrator\ApplicationOrchestrator.cs (3)
691foreach (var child in _parentChildLookup[resource].Where(c => c is IResourceWithParent)) 766if (_parentChildLookup[resource] is { } children) 788if (_parentChildLookup[resource] is { } children)
Aspire.Hosting.Azure (6)
AzureProvisioningController.cs (5)
1261foreach (var child in parentChildLookup[current.Resource]) 1271foreach (var child in parentChildLookup[current.AzureResource]) 3693var childResources = parentChildLookup[resource.Resource].ToList(); 3699foreach (var grandChild in parentChildLookup[child]) 4108if (parentChildLookup[targetResource] is { } children)
AzureResourcePreparer.cs (1)
240var roleAssignments = azureReferencesWithRoleAssignments[azureReference];
Aspire.Hosting.Dotnet (3)
DotnetProjectResource.cs (3)
167if (stepsByName[rootStepName].FirstOrDefault() is { } rootStep) 184if (stepsByName[dependencyStepName].FirstOrDefault() is { } dependencyStep) 190foreach (var requiredStep in requiredStepsByName[step.Name])
Aspire.Hosting.Tests (11)
Orchestrator\RelationshipEvaluatorTests.cs (11)
34Assert.Collection(parentChildLookup[parentResource.Resource], 38Assert.Single(parentChildLookup[childResource.Resource], grandChildResource.Resource); 39Assert.Single(parentChildLookup[grandChildResource.Resource], greatGrandChildResource.Resource); 41Assert.Empty(parentChildLookup[greatGrandChildResource.Resource]); 43Assert.Single(parentChildLookup[childWithAnnotationsResource.Resource], grandChildWithAnnotationsResource.Resource); 45Assert.Empty(parentChildLookup[grandChildWithAnnotationsResource.Resource]); 66Assert.Collection(parentChildLookup[parentResource.Resource], 89Assert.Collection(parentChildLookup[parentResource.Resource], 112Assert.Collection(parentChildLookup[parentResource.Resource], 135Assert.Single(parentChildLookup[grandParentResource.Resource], parentResource.Resource); 136Assert.Single(parentChildLookup[parentResource.Resource], childResource.Resource);
CSharpSyntaxGenerator (1)
TestWriter.cs (1)
187var subTypes = ChildMap[type];
Microsoft.AspNetCore.Mvc.ViewFeatures (1)
ViewComponents\DefaultViewComponentSelector.cs (1)
79var matches = candidates[name];
Microsoft.CodeAnalysis.AnalyzerUtilities (1)
src\roslyn\src\RoslynAnalyzers\Utilities\FlowAnalysis\FlowAnalysis\Framework\DataFlow\AnalysisEntityMapAbstractDomain.cs (1)
95var equivalentKeys2 = map2LookupIgnoringInstanceLocation[key1.EqualsIgnoringInstanceLocationId];
Microsoft.CodeAnalysis.Features (2)
ReplaceMethodWithProperty\ReplaceMethodWithPropertyCodeRefactoringProvider.cs (2)
197getReferencesByDocument[referenceDocument], 198setReferencesByDocument[referenceDocument],
Microsoft.CodeAnalysis.NetAnalyzers (1)
src\9382845807600969\AnalysisEntityMapAbstractDomain.cs (1)
94var equivalentKeys2 = map2LookupIgnoringInstanceLocation[key1.EqualsIgnoringInstanceLocationId];
Microsoft.DotNet.ApiCompatibility (1)
ApiComparer.cs (1)
137sortedCompatDifferences.AddRange(compatDifferencesLookup[elementContainer.MetadataInformation]);
Microsoft.DotNet.Arcade.Sdk (1)
src\InstallDotNetCore.cs (1)
130ProjectProperty property = properties[propertyName].FirstOrDefault();
NuGet.Build.Tasks.Pack (2)
PackTaskLogic.cs (2)
953var libraryIdentities = projectPathToLibraryIdentities[projectReference.ProjectPath]; 956.Select(identity => libraryIdentityToTargetLibrary[identity].FirstOrDefault())
NuGet.Commands (1)
RestoreCommand\ProjectRestoreCommand.cs (1)
132var runtimeIds = runtimesByFramework[graph.Framework];
NuGet.Frameworks (2)
CompatibilityListProvider.cs (2)
44return lookup[false] 47.Concat(lookup[true]);
NuGet.PackageManagement (2)
Utility\FileSystemUtility.cs (1)
284var directoryFiles = directoryLookup.Contains(directory) ? directoryLookup[directory] : Enumerable.Empty<string>();
Utility\MSBuildNuGetProjectSystemUtility.cs (1)
243? directoryLookup[directory]
System.Linq.Queryable (1)
System\Linq\EnumerableRewriter.cs (1)
222MethodInfo[] matchingMethods = s_seqMethods[name]