521 instantiations of XAttribute
aspire (34)
Projects\CSharpProjectFile.cs (7)
191var root = new XElement("Project", new XAttribute("Sdk", Sdk));
217root.Add(Imports.Select(import => new XElement("Import", new XAttribute("Project", import.ProjectPath))));
228var element = new XElement("PackageReference", new XAttribute("Include", packageReference.Name));
232element.Add(new XAttribute(packageReference.VersionAttributeName, packageReference.Version));
243var element = new XElement("ProjectReference", new XAttribute("Include", projectReference.ProjectPath));
254var element = new XElement("None", new XAttribute("Update", noneItem.Update));
258element.Add(new XAttribute("CopyToOutputDirectory", noneItem.CopyToOutputDirectory));
Projects\IntegrationClosureBuilder.cs (23)
81new XAttribute("Name", "_WriteAspireProjectRefAssemblyNames"),
82new XAttribute("AfterTargets", "Build"),
83new XAttribute("Condition", "'$(AspireProjectRefAssemblyNamesFile)' != ''"),
85new XAttribute("File", "$(AspireProjectRefAssemblyNamesFile)"),
86new XAttribute("Lines", "@(_ResolvedProjectReferencePaths->'%(Filename)')"),
87new XAttribute("Overwrite", "true"),
88new XAttribute("WriteOnlyWhenDifferent", "true"))));
92new XAttribute("Name", "_WriteAspireClosureManifest"),
93new XAttribute("AfterTargets", "Build"),
94new XAttribute("Condition", "'$(AspireClosureSourcesFile)' != ''"),
95new XAttribute("DependsOnTargets", "ResolveLockFileCopyLocalFiles"),
97new XAttribute("File", "$(AspireClosureSourcesFile)"),
98new XAttribute("Lines", "@(ReferenceCopyLocalPaths->'%(FullPath)')"),
99new XAttribute("Overwrite", "true"),
100new XAttribute("WriteOnlyWhenDifferent", "true")),
102new XAttribute("File", "$(AspireClosureMetadataFile)"),
103new XAttribute("Lines", "@(ReferenceCopyLocalPaths->'%(NuGetPackageId)|%(NuGetPackageVersion)|%(PathInPackage)|%(AssetType)')"),
104new XAttribute("Overwrite", "true"),
105new XAttribute("WriteOnlyWhenDifferent", "true")),
107new XAttribute("File", "$(AspireClosureTargetsFile)"),
108new XAttribute("Lines", "@(ReferenceCopyLocalPaths->'%(DestinationSubDirectory)%(Filename)%(Extension)')"),
109new XAttribute("Overwrite", "true"),
110new XAttribute("WriteOnlyWhenDifferent", "true"))));
aspire-tray (1)
Aspire.Cli.EndToEnd.Tests (1)
Aspire.Cli.Tests (4)
Aspire.Hosting.Azure.Provisioning.Generators (5)
Aspire.Hosting.Dotnet (17)
DotnetProjectBuildResource.cs (17)
236new XAttribute("DefaultTargets", "Build"),
242new XAttribute(
250new XAttribute("Condition", "'$(NuGetRestoreTargets)' == ''"),
255new XAttribute("Project", "$(NuGetRestoreTargets)"),
256new XAttribute(
292new XAttribute("Importance", "high"),
293new XAttribute("Text", "Restoring projects individually as configured by the AppHost.")));
301new XAttribute("Importance", "high"),
302new XAttribute("Text", "Restoring projects individually because RestoreUseStaticGraphEvaluation is enabled."),
303new XAttribute("Condition", "'$(RestoreUseStaticGraphEvaluation)' == 'true'")),
306new XAttribute("Importance", "high"),
307new XAttribute("Text", "Restoring projects individually because the selected NuGet restore targets are unavailable."),
308new XAttribute(
320new XAttribute("Name", name),
323new XAttribute("Projects", "@(ProjectFile)"),
324new XAttribute("Targets", name),
325new XAttribute("BuildInParallel", buildInParallel)));
Aspire.Hosting.Maui (21)
Utilities\MauiEnvironmentHelper.cs (21)
81new XAttribute("Project", "$(MSBuildExtensionsPath)/v$(MSBuildToolsVersion)/Custom.After.Microsoft.Common.targets"),
82new XAttribute("Condition", "Exists('$(MSBuildExtensionsPath)/v$(MSBuildToolsVersion)/Custom.After.Microsoft.Common.targets')")
90itemGroup.Add(new XElement("_GeneratedAndroidEnvironment", new XAttribute("Include", $"{key}={encodedValue}")));
97new XAttribute("Name", "AspireGenerateAndroidEnvironmentFiles"),
98new XAttribute("BeforeTargets", "_GenerateEnvironmentFiles"),
99new XAttribute("Condition", "'@(_GeneratedAndroidEnvironment)' != ''")
105new XAttribute("File", "$(IntermediateOutputPath)__aspire_environment__.txt"),
106new XAttribute("Lines", "@(_GeneratedAndroidEnvironment)"),
107new XAttribute("Overwrite", "True"),
108new XAttribute("WriteOnlyWhenDifferent", "True")
114new XElement("AndroidEnvironment", new XAttribute("Include", "$(IntermediateOutputPath)__aspire_environment__.txt"))
120new XElement("FileWrites", new XAttribute("Include", "$(IntermediateOutputPath)__aspire_environment__.txt"))
126new XAttribute("Files", "$(_AndroidStampDirectory)_GeneratePackageManagerJava.stamp")
222new XAttribute("Project", "$(MSBuildExtensionsPath)/v$(MSBuildToolsVersion)/Custom.After.Microsoft.Common.targets"),
223new XAttribute("Condition", "Exists('$(MSBuildExtensionsPath)/v$(MSBuildToolsVersion)/Custom.After.Microsoft.Common.targets')")
236new XAttribute("Include", $"{key}={encodedValue}")));
244new XAttribute("Name", "AspireLogMlaunchEnvironmentVariables"),
245new XAttribute("AfterTargets", "PrepareForBuild"),
246new XAttribute("Condition", "'@(MlaunchEnvironmentVariables)' != ''"),
249new XAttribute("Importance", "High"),
250new XAttribute("Text", "Aspire forwarding mlaunch environment variables: @(MlaunchEnvironmentVariables, ', ')")
Aspire.Templates.Tests (4)
Aspire.Tray.Tests (1)
dotnet-svcutil-lib (14)
Shared\MSBuildProj.cs (12)
538this.ProjectReferceGroup.Add(new XElement("ProjectReference", new XAttribute("Include", dependency.FullPath)));
541this.ReferenceGroup.Add(new XElement("Reference", new XAttribute("Include", dependency.AssemblyName), new XElement("HintPath", dependency.FullPath)));
544this.PacakgeReferenceGroup.Add(new XElement("PackageReference", new XAttribute("Include", dependency.Name), new XAttribute("Version", dependency.Version)));
547this.ReferenceGroup.Add(new XElement("DotNetCliToolReference", new XAttribute("Include", dependency.Name), new XAttribute("Version", dependency.Version)));
562new XAttribute("CopyToOutputDirectory", "always"),
563new XAttribute("Include", Path.Combine(basePath, $"{framework}\\**")),
564new XAttribute("Link", $"{framework}/%(RecursiveDir)%(Filename)%(Extension)")));
572new XAttribute("CopyToOutputDirectory", "always"),
573new XAttribute("Include", $"{basePath}\\{framework}\\**"),
574new XAttribute("Link", $"{framework}/%(RecursiveDir)%(Filename)%(Extension)")));
GenerateDocumentationAndConfigFiles (16)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (6)
466new XAttribute(nameof(ID), ID),
467new XAttribute(nameof(Name), Name),
468new XAttribute(nameof(Prefix), Prefix ?? string.Empty),
469new XAttribute(nameof(Suffix), Suffix ?? string.Empty),
470new XAttribute(nameof(WordSeparator), WordSeparator ?? string.Empty),
471new XAttribute(nameof(CapitalizationScheme), CapitalizationScheme));
GenerateTemplateManifest (12)
Program.cs (8)
157sources.Add(new XElement("add", new XAttribute("key", cacheSource), new XAttribute("value", sharedCache)));
162mappings.Add(new XElement("packageSource", new XAttribute("key", cacheSource),
163cachePatterns.Select(pattern => new XElement("package", new XAttribute("pattern", pattern)))));
169new XAttribute("key", localSourceName),
170new XAttribute("value", localPackageFeed)));
172new XAttribute("key", localSourceName),
173builtIds.Order(StringComparer.OrdinalIgnoreCase).Select(id => new XElement("package", new XAttribute("pattern", id)))));
TemplateRestorePlan.cs (4)
147var project = new XElement("Project", new XAttribute("Sdk", "Microsoft.NET.Sdk"),
168project.Add(new XElement("ItemGroup", new XElement("PackageReference", new XAttribute("Include", name), new XAttribute("Version", value))));
304new XElement("Project", new XAttribute("Path", $"{project.Name}/{project.Name}.csproj"))))).Save(solutionPath);
illink (4)
Linker\WarningSuppressionWriter.cs (4)
67var xmlAssembly = new XElement("assembly", new XAttribute("fullname", assemblyName.FullName));
74new XAttribute("fullname", "System.Diagnostics.CodeAnalysis.UnconditionalSuppressMessageAttribute"),
77new XElement("property", new XAttribute("name", UnconditionalSuppressMessageAttributeState.ScopeProperty),
79new XElement("property", new XAttribute("name", UnconditionalSuppressMessageAttributeState.TargetProperty),
Infrastructure.Tests (51)
Hex1bNativePublishingTests.cs (21)
407new XAttribute("Include", source),
417new XAttribute("Include", unrelatedSource),
423new XAttribute("Include", "@(_ResolvedCopyLocalPublishAssets);@(RuntimeTargetsCopyLocalItems)"),
429new XAttribute("Include", Path.Combine(_workspace.Path, "duplicate", "OpenConsole.exe")),
440new XElement("Import", new XAttribute("Project", "Sdk.props"), new XAttribute("Sdk", "Microsoft.NET.Sdk")),
446new XElement("Import", new XAttribute("Project", "Sdk.targets"), new XAttribute("Sdk", "Microsoft.NET.Sdk")),
447new XElement("Import", new XAttribute("Project", Path.Combine(RepoRoot.Path, "src", "Aspire.Hosting", "buildTransitive", "Aspire.Hosting.targets"))),
448new XElement("Target", new XAttribute("Name", "ResolvePackageAssets"), nativeItems),
449new XElement("Target", new XAttribute("Name", "_ResolveCopyLocalAssetsForPublish"),
450new XAttribute("DependsOnTargets", "ResolvePackageAssets"),
452new XAttribute("Include", "@(NativeCopyLocalItems)"),
455new XElement("Target", new XAttribute("Name", "ComputeResolvedFilesToPublishList"),
456new XAttribute("DependsOnTargets", "_ResolveCopyLocalAssetsForPublish"), publishItems),
457new XElement("Target", new XAttribute("Name", "ComputeFilesToPublish"),
458new XAttribute("DependsOnTargets", "ComputeResolvedFilesToPublishList")),
459new XElement("Target", new XAttribute("Name", "CopyTestFiles"),
460new XAttribute("DependsOnTargets", "ComputeFilesToPublish"),
461new XElement("Copy", new XAttribute("SourceFiles", "@(ResolvedFileToPublish)"),
462new XAttribute("DestinationFiles", "@(ResolvedFileToPublish->'$(MSBuildProjectDirectory)/publish/%(RelativePath)')")))));
Shared\TestTrxBuilder.cs (20)
39new XAttribute("total", testCases.Length),
40new XAttribute("executed", testCases.Length),
41new XAttribute("passed", testCases.Count(test => test.Outcome == "Passed")),
42new XAttribute("failed", testCases.Count(test => test.Outcome == "Failed")),
43new XAttribute("error", testCases.Count(test => test.Outcome == "Error")),
44new XAttribute("timeout", testCases.Count(test => test.Outcome == "Timeout")),
45new XAttribute("aborted", 0),
46new XAttribute("inconclusive", 0),
47new XAttribute("passedButRunAborted", 0),
48new XAttribute("notRunnable", 0),
49new XAttribute("notExecuted", 0)))));
96new XAttribute("name", testCase.DisplayName),
97new XAttribute("id", $"test-{index}"),
100new XAttribute("className", testCase.CanonicalTestName[..lastDotIndex]),
101new XAttribute("name", testCase.TestMethodName ?? testCase.CanonicalTestName[(lastDotIndex + 1)..])));
108new XAttribute("testId", $"test-{index}"),
109new XAttribute("testName", testCase.DisplayName),
110new XAttribute("outcome", testCase.Outcome),
114testCase.StartTime is null ? null : new XAttribute("startTime", testCase.StartTime),
115testCase.EndTime is null ? null : new XAttribute("endTime", testCase.EndTime),
TemplateManifest\TemplateManifestTestEnvironment.cs (6)
53new XElement("add", new XAttribute("key", "external"), new XAttribute("value", ExternalFeed))),
56new XElement("packageSource", new XAttribute("key", "external"),
57new XElement("package", new XAttribute("pattern", "*")))),
126new XElement("dependency", new XAttribute("id", dependency.Name),
127new XAttribute("version", dependency.Version))))))).Save(stream);
Microsoft.AspNetCore.DataProtection (17)
KeyManagement\XmlKeyManager.cs (6)
388new XAttribute(VersionAttributeName, 1),
392new XAttribute(IdAttributeName, RevokeAllKeysValue)),
525new XAttribute(IdAttributeName, keyId),
526new XAttribute(VersionAttributeName, 1),
633new XAttribute(VersionAttributeName, 1),
636new XAttribute(IdAttributeName, keyId)),
Microsoft.Build.Tasks.Core (15)
AssemblyDependency\GenerateBindingRedirects.cs (9)
101new XAttribute("name", redirect.Key.Name),
102new XAttribute("publicKeyToken", ResolveAssemblyReference.ByteArrayToString(redirect.Key.GetPublicKeyToken())),
103new XAttribute("culture", String.IsNullOrEmpty(redirect.Key.CultureName) ? "neutral" : redirect.Key.CultureName)),
106new XAttribute("oldVersion", "0.0.0.0-" + redirect.Value),
107new XAttribute("newVersion", redirect.Value))));
301new XAttribute("name", newName),
302new XAttribute(
305new XAttribute(
311attributes.Add(new XAttribute("processorArchitecture", newProcessorArchitecture.ToString()));
Microsoft.CodeAnalysis.Analyzers (16)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (6)
466new XAttribute(nameof(ID), ID),
467new XAttribute(nameof(Name), Name),
468new XAttribute(nameof(Prefix), Prefix ?? string.Empty),
469new XAttribute(nameof(Suffix), Suffix ?? string.Empty),
470new XAttribute(nameof(WordSeparator), WordSeparator ?? string.Empty),
471new XAttribute(nameof(CapitalizationScheme), CapitalizationScheme));
Microsoft.CodeAnalysis.AnalyzerUtilities (16)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (6)
466new XAttribute(nameof(ID), ID),
467new XAttribute(nameof(Name), Name),
468new XAttribute(nameof(Prefix), Prefix ?? string.Empty),
469new XAttribute(nameof(Suffix), Suffix ?? string.Empty),
470new XAttribute(nameof(WordSeparator), WordSeparator ?? string.Empty),
471new XAttribute(nameof(CapitalizationScheme), CapitalizationScheme));
Microsoft.CodeAnalysis.CodeStyle (16)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (6)
466new XAttribute(nameof(ID), ID),
467new XAttribute(nameof(Name), Name),
468new XAttribute(nameof(Prefix), Prefix ?? string.Empty),
469new XAttribute(nameof(Suffix), Suffix ?? string.Empty),
470new XAttribute(nameof(WordSeparator), WordSeparator ?? string.Empty),
471new XAttribute(nameof(CapitalizationScheme), CapitalizationScheme));
Microsoft.CodeAnalysis.ResxSourceGenerator (16)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (6)
466new XAttribute(nameof(ID), ID),
467new XAttribute(nameof(Name), Name),
468new XAttribute(nameof(Prefix), Prefix ?? string.Empty),
469new XAttribute(nameof(Suffix), Suffix ?? string.Empty),
470new XAttribute(nameof(WordSeparator), WordSeparator ?? string.Empty),
471new XAttribute(nameof(CapitalizationScheme), CapitalizationScheme));
Microsoft.CodeAnalysis.Workspaces (36)
Log\WorkspaceStructureLogger.cs (20)
155var referenceElement = new XElement("projectReference", new XAttribute("id", SanitizePath(projectReference.ProjectId.ToString())));
191new XAttribute("id", diagnostic.Id),
192new XAttribute("severity", diagnostic.Severity.ToString()),
193new XAttribute("path", SanitizePath(diagnostic.Location.GetLineSpan().Path)),
204new XAttribute("hintName", document.HintName),
205new XAttribute("path", SanitizePath(document.FilePath)),
206new XAttribute("generatorType", identity.Generator.TypeName),
207new XAttribute("generatorAssembly", identity.Generator.AssemblyName),
208new XAttribute("generatorAssemblyVersion", identity.Generator.AssemblyVersion.ToString()),
209new XAttribute("generatorAssemblyPath", SanitizePath(identity.Generator.AssemblyPath)));
242var aliasesAttribute = new XAttribute("aliases", string.Join(",", reference.Properties.Aliases));
253new XAttribute("file", SanitizePath(portableExecutableReference.FilePath)),
254new XAttribute("display", SanitizePath(portableExecutableReference.Display)),
259return new XElement("metadataReference", new XAttribute("display", SanitizePath(reference.Display)));
265new XAttribute("path", SanitizePath(reference.FullPath)),
266new XAttribute("display", SanitizePath(reference.Display)));
283typesElement.Add(new XElement("type", new XAttribute("name", type.ToDisplayString())));
290new XAttribute("objectId", compilationId.Value),
291new XAttribute("assemblyIdentity", compilation.Assembly.Identity.ToString()),
301var documentElement = new XElement(elementName, new XAttribute("path", SanitizePath(document.FilePath)));
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (6)
466new XAttribute(nameof(ID), ID),
467new XAttribute(nameof(Name), Name),
468new XAttribute(nameof(Prefix), Prefix ?? string.Empty),
469new XAttribute(nameof(Suffix), Suffix ?? string.Empty),
470new XAttribute(nameof(WordSeparator), WordSeparator ?? string.Empty),
471new XAttribute(nameof(CapitalizationScheme), CapitalizationScheme));
Microsoft.DotNet.Build.Manifest (1)
Microsoft.DotNet.Build.Tasks.Installers (8)
src\GenerateMacOSDistributionFile.cs (8)
69new XAttribute("id", component.GetMetadata("FileNameWithExtension")),
70new XAttribute("visible", "true"),
71new XAttribute("title", component.GetMetadata("Title")),
72new XAttribute("description", component.GetMetadata("Description")),
73new XElement("pkg-ref", new XAttribute("id", component.GetMetadata("FileNameWithExtension")))));
90.Select(c => new XElement("line", new XAttribute("choice", c.Attribute("id").Value)));
94new XAttribute("id", component.GetMetadata("FileNameWithExtension")),
110optionsElement.Add(new XAttribute("hostArchitectures", hostArchitecture));
Microsoft.DotNet.Build.Tasks.VisualStudio (1)
Microsoft.DotNet.Build.Tasks.Workloads (15)
Msi\WixDocument.cs (8)
106new XAttribute("Id", id),
107new XAttribute("Value", value)));
115new XAttribute("Id", id)));
123new XAttribute("Id", id)));
141new XAttribute("Id", id),
142new XAttribute("Name", name));
152new XAttribute("Root", root),
153new XAttribute("Key", key));
Msi\WixXmlExtensions.cs (7)
54new XAttribute("Value", value),
55new XAttribute("Type", type),
56new XAttribute("KeyPath", keyPath ? "yes" : "no"));
88new XAttribute("Key", key));
116new XAttribute("Id", id));
136new XAttribute("Id", id),
137new XAttribute("Name", name));
Microsoft.DotNet.HotReload.Watch (1)
Microsoft.DotNet.PackageTesting (10)
VerifyClosure.cs (10)
365new XAttribute("Source", assembly.Name),
366new XAttribute("Target", reference.Name)));
374new XAttribute("Source", assembly.Name),
375new XAttribute("Target", moduleReference)));
385new XAttribute("Id", "native"),
386new XAttribute("Background", "Blue")
390new XAttribute("Id", "managed"),
391new XAttribute("Background", "Green")
405new XAttribute("Id", id),
406new XAttribute("Category", isNative ? "native": "managed")));
Microsoft.DotNet.SharedFramework.Sdk (23)
parent\Microsoft.DotNet.PackageTesting\VerifyClosure.cs (10)
365new XAttribute("Source", assembly.Name),
366new XAttribute("Target", reference.Name)));
374new XAttribute("Source", assembly.Name),
375new XAttribute("Target", moduleReference)));
385new XAttribute("Id", "native"),
386new XAttribute("Background", "Blue")
390new XAttribute("Id", "managed"),
391new XAttribute("Background", "Green")
405new XAttribute("Id", id),
406new XAttribute("Category", isNative ? "native": "managed")));
src\CreateFrameworkListFile.cs (13)
68?.Select(item => new XAttribute(item.ItemSpec, item.GetMetadata("Value")))
169new XAttribute("Type", type),
170new XAttribute("Path", path));
174element.Add(new XAttribute("Language", analyzerLanguage));
180new XAttribute("Culture", Path.GetFileName(Path.GetDirectoryName(path))));
186element.Add(new XAttribute("DropFromSingleFile", "true"));
210new XAttribute("AssemblyName", f.AssemblyName.Name),
211new XAttribute("PublicKeyToken", publicKeyTokenHex),
212new XAttribute("AssemblyVersion", f.AssemblyName.Version));
220element.Add(new XAttribute("FileVersion", f.FileVersion));
230element.Add(new XAttribute("Profile", profile));
237element.Add(new XAttribute("ReferencedByDefault", referencedByDefault));
255element.Add(new XAttribute("DropFromSingleFile", "true"));
Microsoft.DotNet.SourceBuild.Tasks (4)
Microsoft.DotNet.XliffTasks (13)
Model\XlfDocument.cs (10)
51new XAttribute("xmlns", XliffNS.NamespaceName),
52new XAttribute(XNamespace.Xmlns + "xsi", XsiNS.NamespaceName),
53new XAttribute("version", "1.2"),
54new XAttribute(XsiNS + "schemaLocation", $"{XliffNS.NamespaceName} xliff-core-1.2-transitional.xsd"),
56new XAttribute("datatype", "xml"),
57new XAttribute("source-language", "en"),
58new XAttribute("target-language", targetLanguage),
59new XAttribute("original", "_"), // placeholder will be replaced on first update
190new XAttribute("id", sourceNode.Id),
192new XElement(Target, new XAttribute("state", "new"), sourceNode.Source),
Microsoft.Extensions.FileProviders.Embedded.Manifest.Task (2)
Microsoft.Maui.Resizetizer (2)
Microsoft.NET.Build.Tasks (9)
Microsoft.NET.HostModel (12)
ComHost\RegFreeComManifest.cs (12)
30XElement manifest = new XElement(ns + "assembly", new XAttribute("manifestVersion", "1.0"));
32new XAttribute("type", "win32"),
33new XAttribute("name", $"{assemblyName}.X"),
34new XAttribute("version", assemblyVersion)));
56XElement fileElement = new XElement(ns + "file", new XAttribute("name", comHostName));
67XElement comClassElement = new XElement(ns + "comClass", new XAttribute("clsid", guid.ToString("B")), new XAttribute("threadingModel", "Both"));
70comClassElement.Add(new XAttribute("progid", progIdValue.GetString()));
91new XAttribute("tlbid", name.ToString("B")),
92new XAttribute("resourceid", typeLibrary.Key),
93new XAttribute("version", version),
94new XAttribute("helpdir", ""));
Microsoft.NET.Sdk.BlazorWebAssembly.Tasks (7)
Microsoft.NET.Sdk.Publish.Tasks (5)
Microsoft.NET.Sdk.StaticWebAssets.Tasks (8)
NuGet.Commands (14)
RestoreCommand\Utility\BuildAssetsUtils.cs (14)
135new XAttribute("Name", "EmitMSBuildWarning"),
136new XAttribute("BeforeTargets", "Build"),
139new XAttribute("Text", Strings.MSBuildWarning_MultiTarget))));
214new XAttribute("Condition", $" {ExcludeAllCondition} "),
223new XAttribute("Condition", $" {ExcludeAllCondition} "),
236new XAttribute("ToolsVersion", "14.0"),
237new XAttribute("xmlns", Namespace.NamespaceName)));
245new XAttribute("Condition", $" '$({propertyName})' == '' "),
251return new XElement(Namespace + itemName, new XAttribute("Include", path));
257new XAttribute("Project", path),
258new XAttribute("Condition", $"Exists('{path}')"));
264new XAttribute("Include", path),
265new XAttribute("Condition", $"Exists('{path}')"),
337itemGroup.Add(new XAttribute("Condition", conditionValue));
NuGet.Packaging (41)
PackageCreation\Authoring\PackageBuilder.cs (17)
1165new XAttribute("Type", "http://schemas.microsoft.com/packaging/2010/07/manifest"),
1166new XAttribute("Target", $"/{path}"),
1167new XAttribute("Id", GenerateRelationshipId($"/{path}"))),
1169new XAttribute("Type", "http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties"),
1170new XAttribute("Target", $"/{psmdcpPath}"),
1171new XAttribute("Id", GenerateRelationshipId($"/{psmdcpPath}")))
1190new XAttribute("Extension", "rels"),
1191new XAttribute("ContentType", "application/vnd.openxmlformats-package.relationships+xml")),
1193new XAttribute("Extension", "psmdcp"),
1194new XAttribute("ContentType", "application/vnd.openxmlformats-package.core-properties+xml"))
1200new XAttribute("Extension", extension),
1201new XAttribute("ContentType", "application/octet")
1209new XAttribute("PartName", file),
1210new XAttribute("ContentType", "application/octet")
1237new XAttribute(XNamespace.Xmlns + "dc", dcText),
1238new XAttribute(XNamespace.Xmlns + "dcterms", dctermsText),
1239new XAttribute(XNamespace.Xmlns + "xsi", xsiText),
PackageCreation\Xml\PackageMetadataXmlExtensions.cs (13)
202return new XElement(ns + NuspecUtility.FrameworkReference, new XAttribute(NuspecUtility.Name, frameworkReference.Name));
207return new XElement(ns + Reference, new XAttribute(File, reference));
214attributes.Add(new XAttribute("id", dependency.Id));
218attributes.Add(new XAttribute("version", dependency.VersionRange.ToLegacyShortString()));
223attributes.Add(new XAttribute("include", string.Join(",", dependency.Include)));
228attributes.Add(new XAttribute("exclude", string.Join(",", dependency.Exclude)));
245new XAttribute(AssemblyName, reference.AssemblyName),
247new XAttribute("targetFramework", string.Join(", ", reference.SupportedFrameworks.Where(f => f.IsSpecificFramework).Select(f => f.GetFrameworkString()))) :
294attributeList.Add(new XAttribute(NuspecUtility.Type, repository.Type));
299attributeList.Add(new XAttribute(NuspecUtility.RepositoryUrl, repository.Url));
304attributeList.Add(new XAttribute(NuspecUtility.RepositoryBranch, repository!.Branch!));
309attributeList.Add(new XAttribute(NuspecUtility.RepositoryCommit, repository!.Commit!));
352return new XAttribute(name, value);
Roslyn.Diagnostics.Analyzers (16)
src\roslyn\src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (6)
466new XAttribute(nameof(ID), ID),
467new XAttribute(nameof(Name), Name),
468new XAttribute(nameof(Prefix), Prefix ?? string.Empty),
469new XAttribute(nameof(Suffix), Suffix ?? string.Empty),
470new XAttribute(nameof(WordSeparator), WordSeparator ?? string.Empty),
471new XAttribute(nameof(CapitalizationScheme), CapitalizationScheme));
System.Private.Xml.Linq (12)
475 references to XAttribute
Aspire.Hosting.Azure.Provisioning.Generators (2)
dotnet-svcutil-lib (3)
GenerateDocumentationAndConfigFiles (4)
ilc (7)
Microsoft.AspNetCore.DataProtection (1)
Microsoft.AspNetCore.OpenApi.SourceGenerators (3)
Microsoft.AspNetCore.Rewrite (2)
Microsoft.Build.Tasks.Core (13)
Microsoft.CodeAnalysis (3)
Microsoft.CodeAnalysis.Analyzers (4)
Microsoft.CodeAnalysis.AnalyzerUtilities (4)
Microsoft.CodeAnalysis.CodeStyle (3)
Microsoft.CodeAnalysis.CSharp (8)
Microsoft.CodeAnalysis.Features (5)
Microsoft.CodeAnalysis.NetAnalyzers (1)
Microsoft.CodeAnalysis.ResxSourceGenerator (4)
Microsoft.CodeAnalysis.VisualBasic (8)
Microsoft.CodeAnalysis.Workspaces (7)
Microsoft.DotNet.Arcade.Sdk (2)
Microsoft.DotNet.Build.Manifest (2)
Microsoft.DotNet.Build.Tasks.Installers (1)
Microsoft.DotNet.Build.Tasks.Packaging (1)
Microsoft.DotNet.Build.Tasks.VisualStudio (2)
Microsoft.DotNet.NuGetRepack.Tasks (4)
Microsoft.DotNet.SharedFramework.Sdk (1)
Microsoft.DotNet.SourceBuild.Tasks (2)
Microsoft.DotNet.XliffTasks (9)
Microsoft.Maui.Resizetizer (13)
Microsoft.NET.Build.Tasks (2)
Microsoft.NET.Sdk.BlazorWebAssembly.Tasks (1)
Microsoft.NET.Sdk.Publish.Tasks (2)
Microsoft.TestPlatform.Build (1)
netstandard (1)
NuGet.Configuration (7)
NuGet.PackageManagement (10)
NuGet.Packaging (29)
NuGet.Protocol (1)
Roslyn.Diagnostics.Analyzers (4)
sdk-tasks (1)
System.ComponentModel.TypeConverter (13)
System.Private.Xml.Linq (282)
System.Xml.Linq (1)
System.Xml.XDocument (1)