31 references to LicenseType
Microsoft.DotNet.Build.Tasks.Packaging (1)
GenerateNuSpec.cs (1)
218type: LicenseType.Expression,
NuGet.Build.Tasks.Pack (2)
PackTaskLogic.cs (2)
283type: LicenseType.Expression, 310type: LicenseType.File,
NuGet.CommandLine.XPlat (16)
_generated\11\PackageSearchJsonContext.LicenseType.g.cs (9)
13private global::System.Text.Json.Serialization.Metadata.JsonTypeInfo<global::NuGet.Packaging.LicenseType>? _LicenseType; 19public global::System.Text.Json.Serialization.Metadata.JsonTypeInfo<global::NuGet.Packaging.LicenseType> LicenseType 22get => _LicenseType ??= (global::System.Text.Json.Serialization.Metadata.JsonTypeInfo<global::NuGet.Packaging.LicenseType>)Options.GetTypeInfo(typeof(global::NuGet.Packaging.LicenseType)); 25private global::System.Text.Json.Serialization.Metadata.JsonTypeInfo<global::NuGet.Packaging.LicenseType> Create_LicenseType(global::System.Text.Json.JsonSerializerOptions options) 27if (!TryGetTypeInfoForRuntimeCustomConverter<global::NuGet.Packaging.LicenseType>(options, out global::System.Text.Json.Serialization.Metadata.JsonTypeInfo<global::NuGet.Packaging.LicenseType> jsonTypeInfo)) 29jsonTypeInfo = global::System.Text.Json.Serialization.Metadata.JsonMetadataServices.CreateValueInfo<global::NuGet.Packaging.LicenseType>(options, global::System.Text.Json.Serialization.Metadata.JsonMetadataServices.GetEnumConverter<global::NuGet.Packaging.LicenseType>(options));
_generated\36\PackageSearchJsonContext.GetJsonTypeInfo.g.cs (1)
66if (type == typeof(global::NuGet.Packaging.LicenseType))
_generated\8\PackageSearchJsonContext.LicenseMetadata.g.cs (6)
32ObjectWithParameterizedConstructorCreator = static args => new global::NuGet.Packaging.LicenseMetadata((global::NuGet.Packaging.LicenseType)args[0], (string)args[1], (global::NuGet.Packaging.Licenses.NuGetLicenseExpression)args[2], (global::System.Collections.Generic.IReadOnlyList<string>)args[3], (global::System.Version)args[4]), 35ConstructorAttributeProviderFactory = static () => typeof(global::NuGet.Packaging.LicenseMetadata).GetConstructor(InstanceMemberBindingFlags, binder: null, new[] {typeof(global::NuGet.Packaging.LicenseType), typeof(string), typeof(global::NuGet.Packaging.Licenses.NuGetLicenseExpression), typeof(global::System.Collections.Generic.IReadOnlyList<string>), typeof(global::System.Version)}, modifiers: null), 51var info0 = new global::System.Text.Json.Serialization.Metadata.JsonPropertyInfoValues<global::NuGet.Packaging.LicenseType> 66AttributeProviderFactory = static () => typeof(global::NuGet.Packaging.LicenseMetadata).GetProperty("Type", InstanceMemberBindingFlags, null, typeof(global::NuGet.Packaging.LicenseType), global::System.Array.Empty<global::System.Type>(), null), 69properties[0] = global::System.Text.Json.Serialization.Metadata.JsonMetadataServices.CreatePropertyInfo<global::NuGet.Packaging.LicenseType>(options, info0); 209ParameterType = typeof(global::NuGet.Packaging.LicenseType),
NuGet.Packaging (11)
NuspecReader.cs (2)
444var isKnownType = Enum.TryParse(type, ignoreCase: true, result: out LicenseType licenseType); 479if (licenseType == LicenseType.Expression)
PackageCreation\Authoring\LicenseMetadata.cs (4)
26public LicenseType Type { get; } 48public LicenseMetadata(LicenseType type, string license, NuGetLicenseExpression? expression, IReadOnlyList<string>? warningsAndErrors, Version version) 100case LicenseType.File: 103case LicenseType.Expression:
PackageCreation\Authoring\ManifestReader.cs (3)
187if (!Enum.TryParse(type, ignoreCase: true, result: out LicenseType licenseType)) 215case LicenseType.Expression: 236case LicenseType.File:
PackageCreation\Authoring\PackageBuilder.cs (1)
626if (!PackageTypes.Contains(PackageType.SymbolsPackage) && licenseMetadata?.Type == LicenseType.File)
Rules\UnrecognizedLicenseIdentifierRule.cs (1)
26if (licenseMetadata != null && licenseMetadata.Type == LicenseType.Expression && licenseMetadata.LicenseExpression != null)
NuGet.Protocol (1)
Model\PackageSearchMetadata.cs (1)
221return new LicenseMetadata(LicenseType.Expression, license: trimmedLicenseExpression, expression: parsedExpression, warningsAndErrors: errors, version: effectiveVersion);