2 instantiations of LibraryType
NuGet.LibraryModel (2)
LibraryType.cs (2)
65
return new
LibraryType
(value, false);
109
var buildAction = new
LibraryType
(name, true);
110 references to LibraryType
dotnet (1)
ToolPackage\ToolPackageDownloader.cs (1)
161
Type =
LibraryType
.Package,
Microsoft.Build.NuGetSdkResolver (1)
NuGetSdkResolver.cs (1)
190
var libraryIdentity = new LibraryIdentity(sdk.Name, parsedSdkVersion,
LibraryType
.Package);
Microsoft.NET.Build.Tasks (7)
LockFileLookup.cs (7)
24
var
libraryType =
LibraryType
.Parse(library.Type);
26
if (libraryType ==
LibraryType
.Package)
30
if (libraryType ==
LibraryType
.Project)
61
var
libraryType =
LibraryType
.Parse(targetLibrary.Type);
62
if (libraryType ==
LibraryType
.Package)
NuGet.CommandLine.XPlat (10)
Commands\PackageReferenceCommands\AddPackageReferenceCommandRunner.cs (8)
285
(
LibraryType
libraryType, resolvedVersion) = GetPackageVersionFromRestoreResult(restoreResult, packageId, userSpecifiedFrameworks);
287
if (libraryType ==
LibraryType
.Unresolved)
295
if (libraryType ==
LibraryType
.Project ||
296
libraryType ==
LibraryType
.ExternalProject)
455
private static (
LibraryType
, NuGetVersion) GetPackageVersionFromRestoreResult(RestoreResult restoreResult,
487
if (firstMatchingEntry.Key.Type ==
LibraryType
.Project ||
488
firstMatchingEntry.Key.Type ==
LibraryType
.ExternalProject)
499
return (
LibraryType
.Unresolved, null);
Commands\Why\DependencyGraphFinder.cs (2)
128
Type =
LibraryType
.Project,
187
if (library.Type!.Equals(
LibraryType
.Package, StringComparison.OrdinalIgnoreCase))
NuGet.Commands (55)
PackagesLockFileBuilder.cs (6)
23
var libraryLookup = assetsFile.Libraries.Where(e => e.Type ==
LibraryType
.Package)
46
foreach (var library in libraries.Where(e => e.Type ==
LibraryType
.Package))
90
.Where(l => l.Type ==
LibraryType
.Project || l.Type ==
LibraryType
.ExternalProject)
93
foreach (var projectReference in libraries.Where(e => e.Type ==
LibraryType
.Project || e.Type ==
LibraryType
.ExternalProject))
RestoreCommand\CompatibilityChecker.cs (1)
73
if (node.Key.Type ==
LibraryType
.Project)
RestoreCommand\DependencyGraphResolver.cs (8)
591
if (newGraphNode.Item.Key.Type !=
LibraryType
.Project
592
&& newGraphNode.Item.Key.Type !=
LibraryType
.ExternalProject
593
&& newGraphNode.Item.Key.Type !=
LibraryType
.Unresolved
610
LibraryType
.Package)),
630
if (newGraphNode.Item.Key.Type ==
LibraryType
.Unresolved)
688
LibraryType
.Package)),
827
return resolvedDependencyGraphItem.Item.Key.Type ==
LibraryType
.Project;
1017
&& currentGraphItem.Key.Type ==
LibraryType
.Project)
RestoreCommand\Diagnostics\DiagnosticUtility.cs (1)
29
if (identity.Version != null && identity.Type ==
LibraryType
.Package)
RestoreCommand\Diagnostics\IndexedRestoreTargetGraph.cs (1)
85
public GraphItem<RemoteResolveResult> GetItemById(string id,
LibraryType
libraryType)
RestoreCommand\Diagnostics\UnexpectedDependencyMessages.cs (3)
158
var match = indexedGraph.GetItemById(dependency.Name,
LibraryType
.Package);
223
if (dependency.Child.Type !=
LibraryType
.Package)
274
var match = indexedGraph.GetItemById(dependencyId,
LibraryType
.Package);
RestoreCommand\DownloadDependencyResolutionResult.cs (2)
52
if (
LibraryType
.Unresolved == dependency.Item2.Library.Type)
56
else if (
LibraryType
.Package == dependency.Item2.Library.Type)
RestoreCommand\LockFileBuilder.cs (9)
73
if (library.Type ==
LibraryType
.Project || library.Type ==
LibraryType
.ExternalProject)
108
Type =
LibraryType
.Project,
113
else if (library.Type ==
LibraryType
.Package)
204
if (library.Type ==
LibraryType
.Project || library.Type ==
LibraryType
.ExternalProject)
221
else if (library.Type ==
LibraryType
.Package)
534
|| node.Item.Key.Type ==
LibraryType
.Unresolved
668
Type =
LibraryType
.Package,
RestoreCommand\Logging\TransitiveNoWarnUtils.cs (3)
526
private static bool IsProject(
LibraryType
type)
528
return (type ==
LibraryType
.ExternalProject || type ==
LibraryType
.Project);
RestoreCommand\OriginalCaseGlobalPackageFolder.cs (2)
76
.Where(remoteMatch => remoteMatch.Library.Type ==
LibraryType
.Package);
141
if (library.Type ==
LibraryType
.Package)
RestoreCommand\ProjectRestoreCommand.cs (1)
496
if (match == null || match.Library.Type !=
LibraryType
.Package)
RestoreCommand\RestoreCommand.cs (3)
1339
foreach (var library in assetsFile.Libraries.Where(lib => lib.Type ==
LibraryType
.Package))
1423
.Select(dep => new LibraryIdentity(dep.Id, dep.ResolvedVersion,
LibraryType
.Package))
1708
graph.Flattened.Where(e => e.Key.Type !=
LibraryType
.Package)
RestoreCommand\RestoreTargetGraph.cs (2)
160
if (node?.Item?.Key?.Type ==
LibraryType
.Unresolved)
175
if (node?.OuterNode != null && node.Item.Key.Type !=
LibraryType
.Unresolved)
RestoreCommand\SourceRepositoryDependencyProvider.cs (2)
270
Type =
LibraryType
.Package
287
Type =
LibraryType
.Package
RestoreCommand\Utility\AuditUtility.cs (2)
222
if (graph.Flattened.Any(r => r.Key.Type ==
LibraryType
.Package))
382
foreach (GraphItem<RemoteResolveResult>? node in graph.Flattened.Where(r => r.Key.Type ==
LibraryType
.Package))
RestoreCommand\Utility\BuildAssetsUtils.cs (1)
515
targetGraph.Flattened.Where(e => e.Key.Type ==
LibraryType
.Package)
RestoreCommand\Utility\IncludeFlagUtils.cs (6)
208
return item.Key.Type ==
LibraryType
.Package
209
|| item.Key.Type ==
LibraryType
.Project
210
|| item.Key.Type ==
LibraryType
.ExternalProject;
220
if (item.Key.Type ==
LibraryType
.Project)
224
else if (item.Key.Type ==
LibraryType
.ExternalProject)
228
else if (item.Key.Type ==
LibraryType
.Package)
RestoreCommand\Utility\LockFileUtils.cs (2)
187
Type =
LibraryType
.Package,
517
Type =
LibraryType
.Project,
NuGet.DependencyResolver.Core (3)
GraphModel\GraphOperations.cs (1)
338
if ((node.Item?.Key?.Type ==
LibraryType
.Package) == true)
Remote\RemoteWalkContext.cs (1)
115
if (item.Key.Type ==
LibraryType
.Unresolved || !RemoteLibraryProviders.Contains(item.Data.Match.Provider))
ResolverUtility.cs (1)
575
Type =
LibraryType
.Unresolved,
NuGet.LibraryModel (27)
LibraryIdentity.cs (2)
18
public LibraryIdentity(string name, NuGetVersion version,
LibraryType
type)
29
public required
LibraryType
Type { get; set; }
LibraryRange.cs (3)
65
contraintString =
LibraryType
.Reference;
68
contraintString =
LibraryType
.ExternalProject;
72
contraintString =
LibraryType
.Project;
LibraryType.cs (22)
9
public struct LibraryType : IEquatable<
LibraryType
>
11
private static ConcurrentDictionary<string,
LibraryType
> _knownLibraryTypes = new ConcurrentDictionary<string,
LibraryType
>(StringComparer.OrdinalIgnoreCase);
15
public static readonly
LibraryType
Project = Define("project");
20
public static readonly
LibraryType
ExternalProject = Define("externalProject");
25
public static readonly
LibraryType
Package = Define("package");
30
public static readonly
LibraryType
Assembly = Define("assembly");
36
public static readonly
LibraryType
Reference = Define("reference");
41
public static readonly
LibraryType
WinMD = Define("winmd");
46
public static readonly
LibraryType
Unresolved = Define("unresolved");
58
public static
LibraryType
Parse(string value)
60
LibraryType
action;
73
public bool Equals(
LibraryType
other)
80
return obj is
LibraryType
&& Equals((
LibraryType
)obj);
83
public static bool operator ==(
LibraryType
left,
LibraryType
right)
88
public static bool operator !=(
LibraryType
left,
LibraryType
right)
93
public static implicit operator string(
LibraryType
libraryType)
107
private static
LibraryType
Define(string name)
109
var
buildAction = new LibraryType(name, true);
NuGet.PackageManagement (5)
BuildIntegration\BuildIntegratedRestoreUtility.cs (2)
78
.Where(library => library.Type ==
LibraryType
.Package)
92
.Where(library => library.Type ==
LibraryType
.Package)
InstallationCompatibility.cs (1)
55
.Where(result => result.Key.Type ==
LibraryType
.Package)
Utility\BuildIntegratedProjectUtility.cs (2)
78
.Where(library => library.Type ==
LibraryType
.Package)
108
LibraryType
.Parse(targetLibrary.Type));
NuGet.ProjectModel (1)
PackageSpecReferenceDependencyProvider.cs (1)
145
Type =
LibraryType
.Project,