61 references to Constants
Microsoft.Build.Tasks.Core (59)
GenerateApplicationManifest.cs (18)
54
if (Util.CompareFrameworkVersions(TargetFrameworkVersion,
Constants
.TargetFrameworkVersion35) < 0)
104
if (Util.CompareFrameworkVersions(TargetFrameworkVersion,
Constants
.TargetFrameworkVersion35) < 0)
173
if (manifest.EntryPoint == null && Util.CompareFrameworkVersions(TargetFrameworkVersion,
Constants
.TargetFrameworkVersion35) < 0)
190
if (HostInBrowser && Util.CompareFrameworkVersions(TargetFrameworkVersion,
Constants
.TargetFrameworkVersion30) < 0)
300
AssemblyReference clrPlatformAssembly = manifest.AssemblyReferences.Find(
Constants
.CLRPlatformAssemblyName);
306
clrPlatformAssembly.AssemblyIdentity = new AssemblyIdentity(
Constants
.CLRPlatformAssemblyName, ClrVersion);
309
if (Util.CompareFrameworkVersions(TargetFrameworkVersion,
Constants
.TargetFrameworkVersion30) == 0)
311
EnsureAssemblyReferenceExists(manifest, CreateAssemblyIdentity(
Constants
.NET30AssemblyIdentity));
313
else if (Util.CompareFrameworkVersions(TargetFrameworkVersion,
Constants
.TargetFrameworkVersion35) == 0)
315
EnsureAssemblyReferenceExists(manifest, CreateAssemblyIdentity(
Constants
.NET30AssemblyIdentity));
316
EnsureAssemblyReferenceExists(manifest, CreateAssemblyIdentity(
Constants
.NET35AssemblyIdentity));
318
if ((!String.IsNullOrEmpty(TargetFrameworkSubset) && TargetFrameworkSubset.Equals(
Constants
.ClientFrameworkSubset, StringComparison.OrdinalIgnoreCase)) ||
319
(!String.IsNullOrEmpty(TargetFrameworkProfile) && TargetFrameworkProfile.Equals(
Constants
.ClientFrameworkSubset, StringComparison.OrdinalIgnoreCase)))
321
EnsureAssemblyReferenceExists(manifest, CreateAssemblyIdentity(
Constants
.NET35ClientAssemblyIdentity));
325
EnsureAssemblyReferenceExists(manifest, CreateAssemblyIdentity(
Constants
.NET35SP1AssemblyIdentity));
367
if (!Util.IsValidFrameworkVersion(TargetFrameworkVersion) || Util.CompareFrameworkVersions(TargetFrameworkVersion,
Constants
.TargetFrameworkVersion20) < 0)
375
if (GetRequestedExecutionLevel(out string requestedExecutionLevel) && String.CompareOrdinal(requestedExecutionLevel,
Constants
.UACAsInvoker) != 0)
443
requestedExecutionLevel =
Constants
.UACAsInvoker; // For backwards compatibility we assume asInvoker to begin with.
GenerateDeploymentManifest.cs (3)
41
if (Util.CompareFrameworkVersions(TargetFrameworkVersion,
Constants
.TargetFrameworkVersion35) < 0)
62
if (Util.CompareFrameworkVersions(TargetFrameworkVersion,
Constants
.TargetFrameworkVersion35) < 0)
93
if (Util.CompareFrameworkVersions(TargetFrameworkVersion,
Constants
.TargetFrameworkVersion35) < 0)
GenerateLauncher.cs (2)
72
if ((entryPointFileName.Equals(
Constants
.AppHostExe, StringComparison.InvariantCultureIgnoreCase) ||
73
entryPointFileName.Equals(
Constants
.SingleFileHostExe, StringComparison.InvariantCultureIgnoreCase)) &&
GenerateManifestBase.cs (3)
37
private string _targetFrameworkVersion =
Constants
.TargetFrameworkVersion20;
75
return
Constants
.TargetFrameworkVersion35;
546
if (Util.CompareFrameworkVersions(TargetFrameworkVersion,
Constants
.TargetFrameworkVersion35) >= 0)
ManifestUtil\ApplicationManifest.cs (10)
121
AssemblyReference CLRPlatformAssembly = AssemblyReferences.Find(
Constants
.CLRPlatformAssemblyName);
129
CLRPlatformAssembly.AssemblyIdentity = new AssemblyIdentity(
Constants
.CLRPlatformAssemblyName, Util.GetClrVersion(_targetFrameworkVersion));
237
OSVersion = !WinXPRequired ?
Constants
.OSVersion_Win9X :
Constants
.OSVersion_WinXP;
561
if (FileAssociations.Count >
Constants
.MaxFileAssociationsCount)
563
OutputMessages.AddErrorMessage("GenerateManifest.FileAssociationsCountExceedsMaximum",
Constants
.MaxFileAssociationsCount.ToString(CultureInfo.CurrentUICulture));
582
if (fileAssociation.Extension.Length >
Constants
.MaxFileAssociationExtensionLength)
584
OutputMessages.AddErrorMessage("GenerateManifest.FileAssociationExtensionTooLong", fileAssociation.Extension,
Constants
.MaxFileAssociationExtensionLength.ToString(CultureInfo.CurrentUICulture));
734
if (Util.CompareFrameworkVersions(TargetFrameworkVersion,
Constants
.TargetFrameworkVersion35) <= 0)
744
if (assembly.AssemblyIdentity?.IsInFramework(
Constants
.DotNetFrameworkIdentifier, TargetFrameworkVersion) == true)
ManifestUtil\AssemblyReference.cs (1)
93
if (String.Equals(AssemblyIdentity.Name,
Constants
.CLRPlatformAssemblyName, StringComparison.OrdinalIgnoreCase))
ManifestUtil\BaseReference.cs (2)
49
if (path.EndsWith(
Constants
.DeployFileExtension, StringComparison.OrdinalIgnoreCase))
51
path = path.Substring(0, path.Length -
Constants
.DeployFileExtension.Length);
ManifestUtil\Manifest.cs (1)
515
fileName.Equals(
Constants
.AppHostExe, StringComparison.InvariantCultureIgnoreCase))
ManifestUtil\ManifestWriter.cs (1)
106
if (string.IsNullOrEmpty(targetframeWorkVersion) || Util.CompareFrameworkVersions(targetframeWorkVersion,
Constants
.TargetFrameworkVersion40) <= 0)
ManifestUtil\SecurityUtil.cs (2)
583
targetFrameworkIdentifier.Equals(
Constants
.DotNetFrameworkIdentifier, StringComparison.InvariantCultureIgnoreCase))
588
else if (targetFrameworkIdentifier.Equals(
Constants
.DotNetCoreAppIdentifier, StringComparison.InvariantCultureIgnoreCase))
ManifestUtil\TrustInfo.cs (2)
241
executionLevelString =
Constants
.UACAsInvoker;
242
executionUIAccessString =
Constants
.UACUIAccess;
ManifestUtil\Util.cs (1)
246
if (string.IsNullOrEmpty(targetFrameWorkVersion) || CompareFrameworkVersions(targetFrameWorkVersion,
Constants
.TargetFrameworkVersion40) <= 0)
RequiresFramework35SP1Assembly.cs (5)
19
private string _targetFrameworkVersion =
Constants
.TargetFrameworkVersion20;
34
return
Constants
.TargetFrameworkVersion35;
49
if (CompareFrameworkVersions(TargetFrameworkVersion,
Constants
.TargetFrameworkVersion35) < 0)
154
|| string.Equals(candidateFile.ItemSpec,
Constants
.NET35SP1AssemblyIdentity[0], StringComparison.OrdinalIgnoreCase)
155
|| string.Equals(candidateFile.ItemSpec,
Constants
.NET35ClientAssemblyIdentity[0], StringComparison.OrdinalIgnoreCase)))
ResolveManifestFiles.cs (7)
138
return
Constants
.TargetFrameworkVersion35;
151
return
Constants
.DotNetFrameworkIdentifier;
169
bool is35Project = (CompareFrameworkVersions(TargetFrameworkVersion,
Constants
.TargetFrameworkVersion35) >= 0);
291
targetPath.Equals(
Constants
.AppHostExe, StringComparison.InvariantCultureIgnoreCase) &&
739
bool isDotNetCore = String.Equals(TargetFrameworkIdentifier,
Constants
.DotNetCoreAppIdentifier, StringComparison.InvariantCultureIgnoreCase);
767
if (identity?.IsInFramework(
Constants
.DotNetCoreIdentifier, null) == true)
772
else if (identity?.IsInFramework(
Constants
.DotNetFrameworkIdentifier, TargetFrameworkVersion) == true)
SignFile.cs (1)
37
public string TargetFrameworkIdentifier { get; set; } =
Constants
.DotNetFrameworkIdentifier;
Microsoft.Build.Tasks.UnitTests (2)
SecurityUtil_Tests.cs (2)
25
[InlineData("v4.5",
Constants
.DotNetFrameworkIdentifier)]
26
[InlineData("v4.5",
Constants
.DotNetCoreAppIdentifier)]