4 instantiations of RemoteResolveResult
NuGet.Commands (1)
RestoreCommand\DependencyGraphResolver.DependencyGraphItem.cs (1)
134Data = new RemoteResolveResult()
NuGet.DependencyResolver.Core (3)
Remote\RemoteDependencyWalker.cs (1)
325Data = new RemoteResolveResult()
ResolverUtility.cs (2)
148Data = new RemoteResolveResult 560Data = new RemoteResolveResult()
158 references to RemoteResolveResult
NuGet.Commands (83)
RestoreCommand\CompatibilityChecker.cs (1)
341private async Task VerifyDotnetToolCompatibilityChecks(CompatibilityData compatibilityData, GraphItem<RemoteResolveResult> node, RestoreTargetGraph graph, List<CompatibilityIssue> issues)
RestoreCommand\DependencyGraphResolver.cs (29)
325AnalyzeResult<RemoteResolveResult> analyzeResult = new(); 328HashSet<GraphItem<RemoteResolveResult>> flattenedGraphItems = new(); 331List<GraphNode<RemoteResolveResult>> graphNodes = new(); 334Dictionary<LibraryRangeIndex, GraphNode<RemoteResolveResult>> nodesById = new(); 340Queue<(LibraryDependencyIndex, LibraryRangeIndex, GraphNode<RemoteResolveResult>)> itemsToFlatten = new(); 342Dictionary<LibraryRangeIndex, GraphNode<RemoteResolveResult>> versionConflicts = new(); 351GraphNode<RemoteResolveResult> rootGraphNode = new GraphNode<RemoteResolveResult>(projectResolvedDependencyGraphItem.LibraryDependency.LibraryRange) 365(LibraryDependencyIndex currentLibraryDependencyIndex, LibraryRangeIndex currentLibraryRangeIndex, GraphNode<RemoteResolveResult> currentGraphNode) = itemsToFlatten.Dequeue(); 387GraphNode<RemoteResolveResult> nodeWithCycle = new(childLibraryDependency.LibraryRange) 418new GraphNode<RemoteResolveResult>(childLibraryDependency.LibraryRange) 521GraphNode<RemoteResolveResult> nodeWithConflict = new(childResolvedLibraryDependency.LibraryRange) 540GraphNode<RemoteResolveResult> newGraphNode = new(childResolvedLibraryDependency.LibraryRange) 545GraphNode<RemoteResolveResult> parentGraphNode; 609GraphNode<RemoteResolveResult> conflictingNode = new(childLibraryDependency.LibraryRange) 612Item = new GraphItem<RemoteResolveResult>( 657foreach (KeyValuePair<LibraryRangeIndex, GraphNode<RemoteResolveResult>> versionConflict in versionConflicts) 659if (nodesById.TryGetValue(versionConflict.Key, out GraphNode<RemoteResolveResult>? selected)) 662new VersionConflictResult<RemoteResolveResult> 678if (!nodesById.TryGetValue(downgrade.FromParentLibraryRangeIndex, out GraphNode<RemoteResolveResult>? fromParentNode) 679|| !nodesById.TryGetValue(downgrade.ToParentLibraryRangeIndex, out GraphNode<RemoteResolveResult>? toParentNode) 686analyzeResult.Downgrades.Add(new DowngradeResult<RemoteResolveResult> 688DowngradedFrom = new GraphNode<RemoteResolveResult>(downgrade.FromLibraryDependency.LibraryRange) 690Item = new GraphItem<RemoteResolveResult>( 697DowngradedTo = new GraphNode<RemoteResolveResult>(toResolvedDependencyGraphItem.LibraryDependency.LibraryRange) 699Item = new GraphItem<RemoteResolveResult>(toResolvedDependencyGraphItem.Item.Key) 725|| !nodesById.TryGetValue(resolvedDependencyGraphItem.LibraryRangeIndex, out GraphNode<RemoteResolveResult>? currentNode)) 733if (!nodesById.TryGetValue(parentLibraryRangeIndex, out GraphNode<RemoteResolveResult>? parentNode)) 988GraphItem<RemoteResolveResult> currentGraphItem = await currentDependencyGraphItem.GetGraphItemAsync(_request.Project.RestoreMetadata, projectTargetFramework.PackagesToPrune, IsNewerThanNET10(projectTargetFramework.FrameworkName), isRootProject, targetGraphName, _logger);
RestoreCommand\DependencyGraphResolver.DependencyGraphItem.cs (7)
25/// Gets or initializes a <see cref="Task{TResult}" /> that returns a <see cref="GraphItem{TItem}" /> containing a <see cref="RemoteResolveResult" /> that represents the resolved graph item after looking it up in the configured feeds. 27public required Task<GraphItem<RemoteResolveResult>> FindLibraryTask { get; init; } 75/// Gets the <see cref="GraphItem{TItem}" /> with the <see cref="RemoteResolveResult" /> of this dependency graph item from calling the delegate specified in <see cref="FindLibraryTask" />. 81/// <returns>A <see cref="GraphItem{TItem}" /> with the <see cref="RemoteResolveResult" /> of the result of finding the library.</returns> 82public async Task<GraphItem<RemoteResolveResult>> GetGraphItemAsync( 91GraphItem<RemoteResolveResult> item = await FindLibraryTask; 132return new GraphItem<RemoteResolveResult>(item.Key)
RestoreCommand\DependencyGraphResolver.ResolvedDependencyGraphItem.cs (4)
33/// <param name="item">The <see cref="GraphItem{TItem}" /> with a <see cref="RemoteResolveResult" /> of the resolved library.</param> 38GraphItem<RemoteResolveResult> item, 93/// Gets the <see cref="GraphItem{TItem}" /> with a <see cref="RemoteResolveResult" /> of the resolved library. 95public GraphItem<RemoteResolveResult> Item { get; }
RestoreCommand\Diagnostics\IndexedRestoreTargetGraph.cs (4)
18private readonly Dictionary<string, GraphItem<RemoteResolveResult>> _lookup 19= new Dictionary<string, GraphItem<RemoteResolveResult>>(StringComparer.OrdinalIgnoreCase); 72public GraphItem<RemoteResolveResult> GetItemById(string id) 85public GraphItem<RemoteResolveResult> GetItemById(string id, LibraryType libraryType)
RestoreCommand\IRestoreTargetGraph.cs (3)
52IEnumerable<GraphNode<RemoteResolveResult>> Graphs { get; } 56ISet<GraphItem<RemoteResolveResult>> Flattened { get; } 64AnalyzeResult<RemoteResolveResult> AnalyzeResult { get; }
RestoreCommand\LockFileBuilder.cs (8)
61.Distinct(GraphItemKeyComparer<RemoteResolveResult>.Instance) // Distinct list of GraphItems. Two items are equal only if the itmes' Keys are equal. 533HashSet<GraphNode<RemoteResolveResult>> visitedNodes = new HashSet<GraphNode<RemoteResolveResult>>(); 534Queue<GraphNode<RemoteResolveResult>> queue = new Queue<GraphNode<RemoteResolveResult>>(); 536foreach (GraphNode<RemoteResolveResult> rootNode in targetGraph.Graphs) 540foreach (GraphNode<RemoteResolveResult> node in rootNode.InnerNodes) 563foreach (GraphNode<RemoteResolveResult> dependencyNode in EnumerateNodesForDependencyChecks(visitedNodes, queue, rootNode, node))
RestoreCommand\ProjectRestoreCommand.cs (1)
285var graphs = new List<GraphNode<RemoteResolveResult>>
RestoreCommand\RestoreCommand.cs (4)
517foreach (GraphItem<RemoteResolveResult> graphItem in graph.Flattened) 788var restoreTargetGraph = RestoreTargetGraph.Create(_request.Project.RuntimeGraph, Enumerable.Empty<GraphNode<RemoteResolveResult>>(), contextForProject, frameworkRuntimePairs[i].TargetAlias, frameworkRuntimePairs[i].Framework, frameworkRuntimePairs[i].RuntimeIdentifier); 2124allGraphs.Add(RestoreTargetGraph.Create(_request.Project.RuntimeGraph, Enumerable.Empty<GraphNode<RemoteResolveResult>>(), context, frameworkRuntimePair.TargetAlias, frameworkRuntimePair.Framework, frameworkRuntimePair.RuntimeIdentifier)); 2290graphs.Add(RestoreTargetGraph.Create(_request.Project.RuntimeGraph, Enumerable.Empty<GraphNode<RemoteResolveResult>>(), context, frameworkRuntimePair.TargetAlias, frameworkRuntimePair.Framework, frameworkRuntimePair.RuntimeIdentifier));
RestoreCommand\RestoreTargetGraph.cs (9)
47public IEnumerable<GraphNode<RemoteResolveResult>> Graphs { get; } 51public ISet<GraphItem<RemoteResolveResult>> Flattened { get; } 62public AnalyzeResult<RemoteResolveResult> AnalyzeResult { get; } 71IEnumerable<GraphNode<RemoteResolveResult>> graphs, 73ISet<GraphItem<RemoteResolveResult>> flattened, 75AnalyzeResult<RemoteResolveResult> analyzeResult, 114IEnumerable<GraphNode<RemoteResolveResult>> graphs, 121var flattened = new HashSet<GraphItem<RemoteResolveResult>>(); 125var analyzeResult = new AnalyzeResult<RemoteResolveResult>();
RestoreCommand\Utility\AuditUtility.cs (2)
380GraphItem<RemoteResolveResult>? currentProject = graph.Graphs.FirstOrDefault()?.Item; 382foreach (GraphItem<RemoteResolveResult>? node in graph.Flattened.Where(r => r.Key.Type == LibraryType.Package))
RestoreCommand\Utility\BuildAssetsUtils.cs (1)
877ISet<GraphItem<RemoteResolveResult>> items)
RestoreCommand\Utility\IncludeFlagUtils.cs (9)
84var unifiedNodes = new Dictionary<string, GraphItem<RemoteResolveResult>>(StringComparer.OrdinalIgnoreCase); 106GraphItem<RemoteResolveResult> unifiedRoot; 163GraphItem<RemoteResolveResult> child; 185GraphNode<RemoteResolveResult> parent, 186GraphNode<RemoteResolveResult> child) 206private static bool IsPackageOrProject(GraphItem<RemoteResolveResult> item) 218private static int OrderType(GraphItem<RemoteResolveResult> item) 241public DependencyNode(GraphItem<RemoteResolveResult> item, LibraryIncludeFlags dependencyType) 255public GraphItem<RemoteResolveResult> Item { get; }
RestoreCommand\Utility\LockFileUtils.cs (1)
519GraphItem<RemoteResolveResult> graphItem,
NuGet.DependencyResolver.Core (75)
GraphModel\GraphOperations.cs (25)
30public static AnalyzeResult<RemoteResolveResult> Analyze(this GraphNode<RemoteResolveResult> root) 32var result = new AnalyzeResult<RemoteResolveResult>(); 49private static bool IsRelevantDowngrade(DowngradeResult<RemoteResolveResult> d) 53static bool AreAllParentsAccepted(DowngradeResult<RemoteResolveResult> d) 55GraphNode<RemoteResolveResult>? resultToCheck = d.DowngradedFrom.OuterNode; 71this GraphNode<RemoteResolveResult> root, 72List<DowngradeResult<RemoteResolveResult>> downgrades, 73List<GraphNode<RemoteResolveResult>> cycles) 87downgrades.Add(new DowngradeResult<RemoteResolveResult> 97private static void WalkTreeCheckCycleAndNearestWins(CyclesAndDowngrades context, GraphNode<RemoteResolveResult> node) 670private static Dictionary<GraphNode<RemoteResolveResult>, GraphNode<RemoteResolveResult>>? _tempDowngrades; 672public static Dictionary<GraphNode<RemoteResolveResult>, GraphNode<RemoteResolveResult>> RentDowngradesDictionary() 681return new Dictionary<GraphNode<RemoteResolveResult>, GraphNode<RemoteResolveResult>>(); 684public static void ReleaseDowngradesDictionary(Dictionary<GraphNode<RemoteResolveResult>, GraphNode<RemoteResolveResult>> dictionary) 844public List<GraphNode<RemoteResolveResult>> Cycles; 845public Dictionary<GraphNode<RemoteResolveResult>, GraphNode<RemoteResolveResult>> Downgrades; 848private static CyclesAndDowngrades CreateState(List<GraphNode<RemoteResolveResult>> cycles, Dictionary<GraphNode<RemoteResolveResult>, GraphNode<RemoteResolveResult>> downgrades)
Remote\RemoteDependencyWalker.cs (38)
29public async Task<GraphNode<RemoteResolveResult>> WalkAsync(LibraryRange library, NuGetFramework framework, string? runtimeIdentifier, RuntimeGraph? runtimeGraph, bool recursive) 51var transitiveCentralPackageVersionNodes = new List<GraphNode<RemoteResolveResult>>(); 69private async ValueTask<GraphNode<RemoteResolveResult>> CreateGraphNodeAsync( 75GraphEdge<RemoteResolveResult>? outerEdge, 101GraphNode<RemoteResolveResult> rootNode = new GraphNode<RemoteResolveResult>(libraryRange, rootHasInnerNodes, hasParentNodes) 121GraphNode<RemoteResolveResult> node = currentState.GraphNode; 124GraphEdge<RemoteResolveResult>? currentOuterEdge = currentState.OuterEdge; 134GraphItem<RemoteResolveResult> nodeItem = node.Item ?? throw new InvalidOperationException(); 160var innerEdge = new GraphEdge<RemoteResolveResult>(currentOuterEdge, nodeItem, dependency); 198var dependencyNode = new GraphNode<RemoteResolveResult>(dependency.LibraryRange) 223GraphNode<RemoteResolveResult> newNode = new GraphNode<RemoteResolveResult>(graphNodeCreationData.LibraryRange, hasInnerNodes, false) 242GraphItem<RemoteResolveResult> newNodeItem = newNode.Item ?? throw new InvalidOperationException(); 300public static void MergeRuntimeDependencies(HashSet<LibraryDependency>? runtimeDependencies, GraphNode<RemoteResolveResult> node) 305GraphItem<RemoteResolveResult> nodeItem = node.Item ?? throw new InvalidOperationException(); 323node.Item = new GraphItem<RemoteResolveResult>(node.Item.Key) 345GraphEdge<RemoteResolveResult>? graphEdge, 367GraphItem<RemoteResolveResult> item, 383GraphItem<RemoteResolveResult> item, LibraryDependency parentDependency, LibraryRange childDependencyLibrary, bool isRoot) 577GraphNode<RemoteResolveResult> parentNode) 586private async Task<GraphNode<RemoteResolveResult>> AddTransitiveCentralPackageVersionNodesAsync( 587GraphNode<RemoteResolveResult> rootNode, 596GraphNode<RemoteResolveResult> node = await CreateGraphNodeAsync( 631private Dictionary<string, List<GraphNode<RemoteResolveResult>>> _transitiveCentralPackageVersions; 636_transitiveCentralPackageVersions = new Dictionary<string, List<GraphNode<RemoteResolveResult>>>(StringComparer.OrdinalIgnoreCase); 639internal void Add(LibraryDependency centralPackageVersionDependency, GraphNode<RemoteResolveResult> parentNode) 645list = new List<GraphNode<RemoteResolveResult>>(); 660internal void AddParentsToNode(GraphNode<RemoteResolveResult> node) 664List<GraphNode<RemoteResolveResult>> graphNodes = _transitiveCentralPackageVersions[(node.Item ?? throw new InvalidOperationException()).Key.Name]; 695public readonly GraphNode<RemoteResolveResult> GraphNode; 710public readonly GraphEdge<RemoteResolveResult>? OuterEdge; 713GraphNode<RemoteResolveResult> graphNode, 716GraphEdge<RemoteResolveResult>? outerEdge) 733public readonly Task<GraphItem<RemoteResolveResult>> GraphItemTask; 748public readonly GraphEdge<RemoteResolveResult> OuterEdge; 750public GraphNodeCreationData(Task<GraphItem<RemoteResolveResult>> graphItemTask, HashSet<LibraryDependency>? runtimeDependencies, LibraryRange libraryRange, GraphEdge<RemoteResolveResult> outerEdge)
Remote\RemoteWalkContext.cs (4)
26FindLibraryEntryCache = new TaskResultCache<LibraryRangeCacheKey, GraphItem<RemoteResolveResult>>(); 47internal TaskResultCache<LibraryRangeCacheKey, GraphItem<RemoteResolveResult>> FindLibraryEntryCache { get; } 108if (!FindLibraryEntryCache.TryGetValue(key, out Task<GraphItem<RemoteResolveResult>>? task)) 113GraphItem<RemoteResolveResult> item = await task;
ResolverUtility.cs (8)
20public static Task<GraphItem<RemoteResolveResult>> FindLibraryCachedAsync( 36public static async Task<GraphItem<RemoteResolveResult>> FindLibraryEntryAsync( 48GraphItem<RemoteResolveResult>? graphItem = null; 111private static async Task<GraphItem<RemoteResolveResult>> CreateGraphItemAsync( 146return new GraphItem<RemoteResolveResult>(match.Library) 554private static GraphItem<RemoteResolveResult> CreateUnresolvedResult(LibraryRange libraryRange) 558return new GraphItem<RemoteResolveResult>(match.Library) 563Dependencies = RemoteResolveResult.EmptyDependencies