323 references to XElement
Aspire.Hosting.Maui (6)
Utilities\MauiEnvironmentHelper.cs (6)
98projectElement.Add(new XElement( 113var targetElement = new XElement( 121targetElement.Add(new XElement( 281projectElement.Add(new XElement( 304projectElement.Add(new XElement( 309new XElement(
CustomEncryptorSample (1)
CustomXmlEncryptor.cs (1)
26var newElement = new XElement("unencryptedKey",
dotnet-svcutil-lib (6)
Shared\MSBuildProj.cs (6)
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))); 561this.ReferenceGroup.Add(new XElement("Content", 571this.PacakgeReferenceGroup.Add(new XElement("Content", 598XElement element = new XElement(propertyName, null);
EndToEnd.Tests (2)
GivenDotNetUsesMSBuild.cs (2)
55itemGroup.Add(new XElement(ns + "DotNetCliToolReference", 89itemGroup.Add(new XElement(ns + "DotNetCliToolReference",
IIS.LongTests (2)
src\Servers\IIS\IIS\test\Common.LongTests\StartupTests.cs (2)
1410new XElement("binding", 1413new XElement("binding",
IIS.NewHandler.FunctionalTests (2)
src\Servers\IIS\IIS\test\Common.LongTests\StartupTests.cs (2)
1410new XElement("binding", 1413new XElement("binding",
IIS.NewShim.FunctionalTests (2)
src\Servers\IIS\IIS\test\Common.LongTests\StartupTests.cs (2)
1410new XElement("binding", 1413new XElement("binding",
IISExpress.FunctionalTests (2)
src\Servers\IIS\IIS\test\Common.LongTests\StartupTests.cs (2)
1410new XElement("binding", 1413new XElement("binding",
illink (3)
Metrics (5)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleOption2`1.cs (1)
116=> new(XmlElement_CodeStyleOption, // Ensure that we use "CodeStyleOption" as the name for back compat.
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (1)
465=> new(nameof(NamingStyle),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\NamingStylePreferences.cs (1)
343return new XElement("NamingPreferencesInfo",
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SerializableNamingRule.cs (1)
26var element = new XElement(nameof(SerializableNamingRule),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SymbolSpecification.cs (1)
214return new XElement(nameof(SymbolSpecification),
Metrics.Legacy (5)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleOption2`1.cs (1)
116=> new(XmlElement_CodeStyleOption, // Ensure that we use "CodeStyleOption" as the name for back compat.
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (1)
465=> new(nameof(NamingStyle),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\NamingStylePreferences.cs (1)
343return new XElement("NamingPreferencesInfo",
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SerializableNamingRule.cs (1)
26var element = new XElement(nameof(SerializableNamingRule),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SymbolSpecification.cs (1)
214return new XElement(nameof(SymbolSpecification),
Microsoft.AspNetCore.App.Analyzers.Test (2)
RouteEmbeddedLanguage\RoutePatternParserTests.cs (2)
265var parameterElement = new XElement("Parameter", 285new XElement("Diagnostic",
Microsoft.AspNetCore.Authentication.Test (4)
CookieTests.cs (2)
1978xml.Add(result.Ticket.Principal.Claims.Select(claim => new XElement("claim", new XAttribute("type", claim.Type), new XAttribute("value", claim.Value)))); 1982xml.Add(result.Ticket.Properties.Items.Select(extra => new XElement("extra", new XAttribute("type", extra.Key), new XAttribute("value", extra.Value))));
TestExtensions.cs (2)
55new XElement("claim", new XAttribute("type", claim.Type), 73xml.Add(new XElement("token", new XAttribute("name", token.Name),
Microsoft.AspNetCore.DataProtection (16)
AuthenticatedEncryption\ConfigurationModel\AuthenticatedEncryptorDescriptor.cs (1)
51var outerElement = new XElement("descriptor",
AuthenticatedEncryption\ConfigurationModel\CngCbcAuthenticatedEncryptorDescriptor.cs (2)
46var encryptionElement = new XElement("encryption", 61var rootElement = new XElement("descriptor",
AuthenticatedEncryption\ConfigurationModel\CngGcmAuthenticatedEncryptorDescriptor.cs (2)
45var encryptionElement = new XElement("encryption", 53var rootElement = new XElement("descriptor",
AuthenticatedEncryption\ConfigurationModel\ManagedAuthenticatedEncryptorDescriptor.cs (2)
45var encryptionElement = new XElement("encryption", 52var rootElement = new XElement("descriptor",
AuthenticatedEncryption\ConfigurationModel\SecretExtensions.cs (1)
37var masterKeyElement = new XElement("masterKey",
KeyManagement\XmlKeyManager.cs (4)
387var revocationElement = new XElement(RevocationElementName, 524var keyElement = new XElement(KeyElementName, 530new XElement(DescriptorElementName, 632var revocationElement = new XElement(RevocationElementName,
XmlEncryption\DpapiNGXmlEncryptor.cs (1)
85var element = new XElement("encryptedKey",
XmlEncryption\DpapiXmlEncryptor.cs (1)
82var element = new XElement("encryptedKey",
XmlEncryption\NullXmlEncryptor.cs (1)
56var newElement = new XElement("unencryptedKey",
XmlEncryption\XmlEncryptionExtensions.cs (1)
150new XElement(XmlConstants.EncryptedSecretElementName,
Microsoft.AspNetCore.Identity.InMemory.Test (2)
FunctionalTest.cs (2)
412xml.Add(result.Principal.Claims.Select(claim => new XElement("claim", new XAttribute("type", claim.Type), new XAttribute("value", claim.Value)))); 416xml.Add(result.Properties.Items.Select(extra => new XElement("extra", new XAttribute("type", extra.Key), new XAttribute("value", extra.Value))));
Microsoft.AspNetCore.Mvc.Formatters.Xml.Test (1)
XmlAssert.cs (1)
70return new XElement(
Microsoft.AspNetCore.Mvc.FunctionalTests (1)
src\Mvc\Mvc.Formatters.Xml\test\XmlAssert.cs (1)
70return new XElement(
Microsoft.Build.Tasks.Core (5)
AssemblyDependency\GenerateBindingRedirects.cs (3)
93new XElement( 95new XElement( 100new XElement(
AssemblyDependency\ResolveAssemblyReference.cs (2)
1262new XElement( 1267new XElement(
Microsoft.Cci.Extensions (2)
Dgml\DgmlExtensions.cs (2)
41var xNode = new XElement(XName.Get("Node", dgmlNsp), 54var xLink = new XElement(XName.Get("Link", dgmlNsp),
Microsoft.CodeAnalysis.Analyzers (5)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleOption2`1.cs (1)
116=> new(XmlElement_CodeStyleOption, // Ensure that we use "CodeStyleOption" as the name for back compat.
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (1)
465=> new(nameof(NamingStyle),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\NamingStylePreferences.cs (1)
343return new XElement("NamingPreferencesInfo",
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SerializableNamingRule.cs (1)
26var element = new XElement(nameof(SerializableNamingRule),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SymbolSpecification.cs (1)
214return new XElement(nameof(SymbolSpecification),
Microsoft.CodeAnalysis.AnalyzerUtilities (5)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleOption2`1.cs (1)
116=> new(XmlElement_CodeStyleOption, // Ensure that we use "CodeStyleOption" as the name for back compat.
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (1)
465=> new(nameof(NamingStyle),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\NamingStylePreferences.cs (1)
343return new XElement("NamingPreferencesInfo",
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SerializableNamingRule.cs (1)
26var element = new XElement(nameof(SerializableNamingRule),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SymbolSpecification.cs (1)
214return new XElement(nameof(SymbolSpecification),
Microsoft.CodeAnalysis.BannedApiAnalyzers (5)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleOption2`1.cs (1)
116=> new(XmlElement_CodeStyleOption, // Ensure that we use "CodeStyleOption" as the name for back compat.
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (1)
465=> new(nameof(NamingStyle),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\NamingStylePreferences.cs (1)
343return new XElement("NamingPreferencesInfo",
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SerializableNamingRule.cs (1)
26var element = new XElement(nameof(SerializableNamingRule),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SymbolSpecification.cs (1)
214return new XElement(nameof(SymbolSpecification),
Microsoft.CodeAnalysis.CodeStyle (5)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleOption2`1.cs (1)
116=> new(XmlElement_CodeStyleOption, // Ensure that we use "CodeStyleOption" as the name for back compat.
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (1)
465=> new(nameof(NamingStyle),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\NamingStylePreferences.cs (1)
343return new XElement("NamingPreferencesInfo",
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SerializableNamingRule.cs (1)
26var element = new XElement(nameof(SerializableNamingRule),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SymbolSpecification.cs (1)
214return new XElement(nameof(SymbolSpecification),
Microsoft.CodeAnalysis.CSharp.EditorFeatures2.UnitTests (8)
EmbeddedLanguages\Json\CSharpJsonParserTests.cs (4)
268=> new( 277=> new( 284=> new( 290=> new(
EmbeddedLanguages\RegularExpressions\CSharpRegexParserTests.cs (4)
187element.Add(new XElement("Captures", 189new XElement("Capture", new XAttribute("Name", kvp.Key), new XAttribute("Span", kvp.Value), GetTextAttribute(text, kvp.Value))), 191new XElement("Capture", new XAttribute("Name", kvp.Key), new XAttribute("Span", kvp.Value), GetTextAttribute(text, kvp.Value))))); 199new XElement("Diagnostic",
Microsoft.CodeAnalysis.PerformanceSensitiveAnalyzers (5)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleOption2`1.cs (1)
116=> new(XmlElement_CodeStyleOption, // Ensure that we use "CodeStyleOption" as the name for back compat.
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (1)
465=> new(nameof(NamingStyle),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\NamingStylePreferences.cs (1)
343return new XElement("NamingPreferencesInfo",
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SerializableNamingRule.cs (1)
26var element = new XElement(nameof(SerializableNamingRule),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SymbolSpecification.cs (1)
214return new XElement(nameof(SymbolSpecification),
Microsoft.CodeAnalysis.PublicApiAnalyzers (5)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleOption2`1.cs (1)
116=> new(XmlElement_CodeStyleOption, // Ensure that we use "CodeStyleOption" as the name for back compat.
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (1)
465=> new(nameof(NamingStyle),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\NamingStylePreferences.cs (1)
343return new XElement("NamingPreferencesInfo",
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SerializableNamingRule.cs (1)
26var element = new XElement(nameof(SerializableNamingRule),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SymbolSpecification.cs (1)
214return new XElement(nameof(SymbolSpecification),
Microsoft.CodeAnalysis.ResxSourceGenerator (5)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleOption2`1.cs (1)
116=> new(XmlElement_CodeStyleOption, // Ensure that we use "CodeStyleOption" as the name for back compat.
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (1)
465=> new(nameof(NamingStyle),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\NamingStylePreferences.cs (1)
343return new XElement("NamingPreferencesInfo",
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SerializableNamingRule.cs (1)
26var element = new XElement(nameof(SerializableNamingRule),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SymbolSpecification.cs (1)
214return new XElement(nameof(SymbolSpecification),
Microsoft.CodeAnalysis.SemanticSearch.Extensions (1)
ProjectModel.cs (1)
121newDocument.Root!.Add(new XElement("data",
Microsoft.CodeAnalysis.Test.Utilities (4)
InstrumentationChecker.cs (1)
273public static readonly XElement InstrumentationHelperSource = new XElement("file", new XAttribute("name", "c.vb"), InstrumentationHelperSourceStr);
Syntax\XmlHelpers.cs (3)
123xml = new XElement("Node", 164XElement retVal = new XElement("Node", 217XElement retVal = new XElement("Node",
Microsoft.CodeAnalysis.Workspaces (5)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleOption2`1.cs (1)
116=> new(XmlElement_CodeStyleOption, // Ensure that we use "CodeStyleOption" as the name for back compat.
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (1)
465=> new(nameof(NamingStyle),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\NamingStylePreferences.cs (1)
343return new XElement("NamingPreferencesInfo",
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SerializableNamingRule.cs (1)
26var element = new XElement(nameof(SerializableNamingRule),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SymbolSpecification.cs (1)
214return new XElement(nameof(SymbolSpecification),
Microsoft.CodeAnalysis.Workspaces.Test.Utilities (4)
Workspaces\TestWorkspace_XmlCreation.cs (4)
79return new XElement(WorkspaceElementName, projectElements); 90return new XElement(ProjectElementName, 191var element = new XElement(DocumentElementName, 208return new XElement(DocumentFromSourceGeneratorElementName,
Microsoft.DotNet.Build.Manifest (4)
BlobArtifactModel.cs (1)
17public override XElement ToXml() => new XElement(
BuildModel.cs (1)
26public XElement ToXml() => new XElement(
PackageArtifactModel.cs (1)
60public override XElement ToXml() => new XElement(
PdbArtifactModel.cs (1)
29public override XElement ToXml() => new XElement(
Microsoft.DotNet.Build.Tasks.Installers (2)
src\GenerateMacOSDistributionFile.cs (2)
65.Select(component => new XElement("choice", 90.Select(component => new XElement("pkg-ref",
Microsoft.DotNet.Build.Tasks.Workloads (4)
Msi\MsiPayloadPackageProject.wix.cs (1)
61itemGroup.Add(new XElement("None",
Msi\WorkloadPackGroupMsi.wix.cs (3)
105registryKeyElement.Add(new XElement(ns + "RegistryKey", new XAttribute("Key", pack.Id), 106new XElement(ns + "RegistryKey", new XAttribute("Key", pack.PackageVersion), 107new XElement(ns + "RegistryValue", new XAttribute("Value", ""), new XAttribute("Type", "string")))));
Microsoft.DotNet.PackageTesting (5)
VerifyClosure.cs (5)
360linksElement.Add(new XElement(s_dgmlns + "Link", 369linksElement.Add(new XElement(s_dgmlns + "Link", 380categoriesElement.Add(new XElement(s_dgmlns + "Category", 385categoriesElement.Add(new XElement(s_dgmlns + "Category", 400parent.Add(new XElement(s_dgmlns + "Node",
Microsoft.DotNet.SharedFramework.Sdk (7)
src\CreateFrameworkListFile.cs (2)
67var frameworkManifest = new XElement("FileList", rootAttributes); 158var element = new XElement(
src\Microsoft.DotNet.PackageTesting\VerifyClosure.cs (5)
360linksElement.Add(new XElement(s_dgmlns + "Link", 369linksElement.Add(new XElement(s_dgmlns + "Link", 380categoriesElement.Add(new XElement(s_dgmlns + "Category", 385categoriesElement.Add(new XElement(s_dgmlns + "Category", 400parent.Add(new XElement(s_dgmlns + "Node",
Microsoft.DotNet.SourceBuild.Tasks (5)
src\UsageReport\AnnotatedUsage.cs (1)
19public XElement ToXml() => new XElement(
src\UsageReport\Usage.cs (1)
30public XElement ToXml() => new XElement(
src\UsageReport\UsageData.cs (1)
18public XElement ToXml() => new XElement(
src\UsageReport\UsagePattern.cs (1)
15public XElement ToXml() => new XElement(
src\UsageReport\XmlParsingHelpers.cs (1)
15public static XElement ToXElement(this PackageIdentity ident) => new XElement(
Microsoft.DotNet.XliffTasks (4)
Model\XlfDocument.cs (4)
49new XElement(Xliff, 54new XElement(File, 188new(TransUnit, 191new XElement(Target, new XAttribute("state", "new"), sourceNode.Source),
Microsoft.DotNet.XliffTasks.Tests (7)
XElementExtensionsTests.cs (7)
17new(TransUnit, 30new(TransUnit, 55new(TransUnit, 69new(TransUnit, 118new(TransUnit, 120new XElement(Target, 133new(TransUnit,
Microsoft.Extensions.FileProviders.Embedded.Tests (3)
Manifest\TestEntry.cs (2)
24new XElement("File", new XAttribute("Name", Name), new XElement("ResourcePath", ResourcePath)) : 25new XElement("Directory", new XAttribute("Name", Name), Children.Select(c => c.ToXElement()));
TestAssembly.cs (1)
34new XElement("Manifest",
Microsoft.ML.Maml (2)
HelpCommand.cs (2)
466select new XElement("Component", 481select new XElement("Argument",
Microsoft.NET.Build.Tasks (2)
GenerateToolsSettingsFile.cs (1)
93var dotnetCliToolNode = new XElement("DotNetCliTool",
WriteAppConfigWithSupportedRuntime.cs (1)
133new XElement(
Microsoft.NET.Build.Tasks.UnitTests (1)
GivenWriteAppConfigWithSupportedRuntimeTask.cs (1)
54new XElement("supportedRuntime",
Microsoft.NET.Build.Tests (66)
COMReferenceTests.cs (3)
41new XElement("COMReference", 88new XElement("COMReference", 100new XElement("COMReference",
DepsFileSkipTests.cs (4)
203var target = new XElement(ns + "Target", 218var fileToSkipItem = new XElement(ns + "_FileToSkip", 226var fileToSkipItem = new XElement(ns + "_FileToSkip", 233var conflictItem = new XElement(ns + "_ConflictPackageFiles",
GivenFrameworkReferences.cs (4)
284itemGroup.Add(new XElement(ns + "KnownFrameworkReference", 810itemGroup.Add(new XElement(ns + "FrameworkReference", 1091var knownFrameworkReferenceUpdate = new XElement(ns + "KnownFrameworkReference", 1098var knownAppHostPackUpdate = new XElement(ns + "KnownAppHostPack",
GivenThatWeWantToBuildAComServerLibrary.cs (8)
175new XElement("ItemGroup", 196new XElement("ItemGroup", 197new XElement("ComHostTypeLibrary", new XAttribute("Include", "dummy1.tlb"), new XAttribute("Id", 1)), 198new XElement("ComHostTypeLibrary", new XAttribute("Include", "dummy2.tlb"), new XAttribute("Id", 1))))); 222new XElement("ComHostTypeLibrary", new XAttribute("Include", "dummy1.tlb"), new XAttribute("Id", id))))); 241new XElement("ItemGroup", 242new XElement("ComHostTypeLibrary", new XAttribute("Include", "dummy1.tlb"), new XAttribute("Id", 1)), 243new XElement("ComHostTypeLibrary", new XAttribute("Include", "dummy2.tlb"), new XAttribute("Id", 2)))));
GivenThatWeWantToBuildACrossTargetedLibrary.cs (2)
98new XElement(ns + "PropertyGroup", 102new XElement(ns + "PropertyGroup",
GivenThatWeWantToBuildADesktopExe.cs (2)
509itemGroup.Add(new XElement(ns + "PackageReference", 573itemGroup.Add(new XElement(ns + "PackageReference",
GivenThatWeWantToBuildADesktopExeWtihNetStandardLib.cs (7)
52itemGroup.Add(new XElement(ns + "Reference", 198itemGroup.Add(new XElement(ns + "PackageReference", 204var target = new XElement(ns + "Target", 209target.Add(new XElement(ns + "FindUnderPath", 212new XElement(ns + "Output", 216target.Add(new XElement(ns + "Message", 220target.Add(new XElement(ns + "Error",
GivenThatWeWantToBuildADesktopLibrary.cs (5)
357itemGroup.Add(new XElement(ns + "PackageReference", 363itemGroup.Add(new XElement(ns + "PackageReference", 417itemGroup.Add(new XElement(ns + "PackageReference", 482new XElement(ns + "Reference", 530p.Root.Add(new XElement(pns + "Target",
GivenThatWeWantToBuildAnAppWithTransitiveNonSdkProjectRefs.cs (1)
56var target = new XElement(ns + "Target",
GivenThatWeWantToBuildANetCoreApp.cs (2)
349itemGroup.Add(new XElement(ns + "PackageReference", 471itemGroup.Add(new XElement(ns + "PackageReference",
GivenThatWeWantToBuildANetStandard2Library.cs (1)
62itemGroup.Add(new XElement(ns + "PackageReference",
GivenThatWeWantToControlGeneratedAssemblyInfo.cs (9)
117new XElement(ns + "Target", 148new XElement(ns + "Target", 154new XElement(ns + "PropertyGroup", 180new XElement(ns + "Target", 216new XElement(ns + "Target", 227new XElement(ns + "PropertyGroup", 571new XElement(ns + "InternalsVisibleTo", 624new XElement(ns + "AssemblyMetadata", 652new XElement(ns + "AssemblyMetadata",
GivenThatWeWantToCopyPPFileToOutput.cs (2)
67itemGroup.Add(new XElement(ns + "Content", new XAttribute("Include", "Nontransformed.ps1"), 69itemGroup.Add(new XElement(ns + "Content", new XAttribute("Include", "Test.ps1.pp"),
GivenThatWeWantToGenerateADepsFileForATool.cs (1)
126itemGroup.Add(new XElement(ns + "DotNetCliToolReference",
GivenThatWeWantToReferenceAProject.cs (3)
214var content = new XElement(ns + "Content", 224var target = new XElement(ns + "Target", 266new XElement(ns + "Content", new XAttribute("Include", "a.txt"), new XAttribute("CopyToOutputDirectory", "PreserveNewest"))));
GivenThatWeWantToResolveConflicts.cs (1)
164itemGroup.Add(new XElement(ns + "Reference",
GivenThatWeWantToTargetNet471.cs (1)
311var referenceElement = new XElement(ns + "Reference",
GivenThatWeWantToUseAnalyzers.cs (3)
238new XElement(ns + "ItemGroup", 239new XElement(ns + "PackageReference", 242new XElement(ns + "PackageReference",
GivenThereAreDefaultItems.cs (3)
314itemGroup.Add(new XElement(ns + "Content", new XAttribute("Include", "CSharpAsContent.cs"), 454itemGroup.Add(new XElement(ns + "None", new XAttribute("Update", "@(None)"), new XAttribute("CopyToOutputDirectory", "PreserveNewest"))); 566itemGroup.Add(new XElement(ns + "PackageReference",
KnownRuntimePackTests.cs (3)
85var frameworkReferenceUpdate = new XElement("FrameworkReference", 119var knownFrameworkReferenceUpdate = new XElement("KnownFrameworkReference", 143var knownRuntimePack = new XElement("KnownRuntimePack",
SourceLinkTests.cs (1)
93itemGroup.Add(new XElement(ns + key, (object[])attributes));
Microsoft.NET.Pack.Tests (2)
GivenThatWeWantToPackACppCliProject.cs (1)
36itemGroup.Add(new XElement(ns + "PackageReference", new XAttribute("Include", package),
GivenThatWeWantToPackANetFrameworkLibrary.cs (1)
52p.Root.Add(new XElement(pns + "ItemGroup",
Microsoft.NET.Publish.Tests (23)
GivenThatWeWantToExcludeAPackageFromPublish.cs (3)
32itemGroup.Add(new XElement(ns + "PackageReference", new XAttribute("Include", "NEWTONSOFT.Json"), 82itemGroup.Add(new XElement(ns + "PackageReference", new XAttribute("Include", "Newtonsoft.Json"), 132itemGroup.Add(new XElement(ns + "PackageReference", new XAttribute("Include", "Newtonsoft.Json"),
GivenThatWeWantToPublishAHelloWorldProject.cs (1)
300itemGroup.Add(new XElement(ns + "PackageReference",
GivenThatWeWantToPublishAnAotApp.cs (4)
547new XElement(ns + "KnownILCompilerPack", 1033target = new XElement(ns + "Target", 1040new XElement("ManagedAssemblyToLink", 1272new XElement("RuntimeHostConfigurationOption",
GivenThatWeWantToPublishASingleFileApp.cs (6)
1044var target = new XElement(ns + "Target", 1053new XElement(ns + "Error", 1062new XElement(ns + "Error", 1094var target = new XElement(ns + "Target", 1109new XElement(ns + "Move", 1124new XElement(ns + "FilesToBundle",
GivenThatWeWantToRunILLink.cs (5)
1900target = new XElement(ns + "Target", 1907new XElement("ManagedAssemblyToLink", 1941var target = new XElement(ns + "Target", 1947items.Add(new XElement("ManagedAssemblyToLink", 1981new XElement("RuntimeHostConfigurationOption",
PublishTestUtils.cs (4)
119project.Root.Add(new XElement(ns + "PropertyGroup", 123project.Root.Add(new XElement(ns + "PropertyGroup", 127project.Root.Add(new XElement(ns + "PropertyGroup", 131project.Root.Add(new XElement(ns + "PropertyGroup",
Microsoft.NET.Restore.Tests (4)
GivenThatWeWantAutomaticTargetingPackReferences.cs (4)
79itemGroup.Add(new XElement(ns + "PackageReference", 145itemGroup.Add(new XElement(ns + "PackageReference", 148itemGroup.Add(new XElement(ns + "PackageReference", 151itemGroup.Add(new XElement(ns + "PackageReference",
Microsoft.NET.Sdk.BlazorWebAssembly.Tasks (2)
BlazorWriteSatelliteAssemblyFile.cs (1)
34root.Add(new XElement("Assembly",
CreateBlazorTrimmerRootDescriptorFile.cs (1)
61roots.Add(new XElement("assembly",
Microsoft.NET.Sdk.BlazorWebAssembly.Tests (4)
WasmBuildIntegrationTest.cs (2)
674new XElement(ns + "Reference", 750new XElement(ns + "Reference",
WasmJsModulesIntegrationTests.cs (1)
177new XElement("Content",
WasmPublishIntegrationTest.cs (1)
1582new XElement(ns + "Reference",
Microsoft.NET.Sdk.Publish.Tasks (1)
Tasks\GenerateEnvTransform.cs (1)
77new XElement("environmentVariable", new XAttribute("name", envVariable.Key),
Microsoft.NET.Sdk.Publish.Tasks.Tests (1)
WebConfigTransformTests.cs (1)
247new XElement("environmentVariable", new XAttribute("name", "ENVVAR"), new XAttribute("value", "123"));
Microsoft.NET.Sdk.StaticWebAssets.Tasks (5)
GenerateStaticWebAssetEndpointsPropsFile.cs (1)
54itemGroup.Add(new XElement(nameof(StaticWebAssetEndpoint),
GenerateStaticWebAssetsPropsFile.cs (1)
71itemGroup.Add(new XElement("StaticWebAsset",
Legacy\GenerateStaticWebAssetsPropsFile50.cs (1)
62itemGroup.Add(new XElement("StaticWebAsset",
Legacy\GenerateV1StaticWebAssetsManifest.cs (2)
38var root = new XElement( 123nodes.Add(new XElement("ContentRoot",
Microsoft.NET.Sdk.StaticWebAssets.Tests (8)
JsModulesIntegrationTest.cs (1)
297new XElement("Content",
StaticWebAssetEndpointsIntegrationTest.cs (3)
297new XElement("ItemGroup", 298new XElement("Content", 301new XElement("Content",
StaticWebAssetsIntegrationTest.cs (4)
552new XElement( 585document.Root.AddFirst(new XElement("ItemGroup", 586new XElement("Content", 590new XElement("Content",
Microsoft.NET.TestFramework (10)
Commands\GetValuesCommand.cs (2)
106var target = new XElement(ns + "Target", 131new XElement(ns + "WriteLinesToFile",
NuGetConfigWriter.cs (1)
24packageSources.Add(new XElement("add",
ProjectConstruction\TestProject.cs (5)
215packageReferenceItemGroup.Add(new XElement(ns + "DotNetCliToolReference", 348var target = new XElement(ns + "Target", 352var copyElement = new XElement(ns + "Copy", 381var target = new XElement(ns + "Target", 398new XElement(ns + "WriteLinesToFile",
Utilities\ProjectModification.cs (2)
16XElement target = new(ns + "Target", new XAttribute("Name", "DisplayMessages"), 20target.Add(new XElement(ns + "Message", new XAttribute("Text", "Important text"),
Microsoft.NET.ToolPack.Tests (1)
GivenThatWeWantToPackAToolProjectWithComplexNugetDependency.cs (1)
65itemGroup.Add(new XElement(ns + "PackageReference", new XAttribute("Include", "System.Data.SqlClient"),
Microsoft.VisualStudio.LanguageServices (7)
Snippets\SnippetExpansionClient.cs (7)
655declarations.Add(new XElement( 667declarations.Add(new XElement( 687new XElement( 690new XElement( 694new XElement( 696new XElement(snippetNamespace + "Declarations", declarations.ToArray()), 697new XElement(
Microsoft.VisualStudio.LanguageServices.Implementation (2)
SolutionExplorer\RuleSetDocumentExtensions.cs (2)
85ruleElement = new XElement("Rule", 102rulesElement = new XElement("Rules",
Roslyn.Diagnostics.Analyzers (5)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleOption2`1.cs (1)
116=> new(XmlElement_CodeStyleOption, // Ensure that we use "CodeStyleOption" as the name for back compat.
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (1)
465=> new(nameof(NamingStyle),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\NamingStylePreferences.cs (1)
343return new XElement("NamingPreferencesInfo",
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SerializableNamingRule.cs (1)
26var element = new XElement(nameof(SerializableNamingRule),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SymbolSpecification.cs (1)
214return new XElement(nameof(SymbolSpecification),
Text.Analyzers (5)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleOption2`1.cs (1)
116=> new(XmlElement_CodeStyleOption, // Ensure that we use "CodeStyleOption" as the name for back compat.
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (1)
465=> new(nameof(NamingStyle),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\NamingStylePreferences.cs (1)
343return new XElement("NamingPreferencesInfo",
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SerializableNamingRule.cs (1)
26var element = new XElement(nameof(SerializableNamingRule),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SymbolSpecification.cs (1)
214return new XElement(nameof(SymbolSpecification),
XmlFileLogger (5)
ObjectModel\Build.cs (1)
47var root = new XElement("Build",
ObjectModel\Message.cs (1)
36element.Add(new XElement("Message", new XAttribute("Timestamp", _timestamp), new XText(_message)));
ObjectModel\Project.cs (1)
98var element = new XElement("Project",
ObjectModel\Target.cs (1)
35var element = new XElement("Target",
ObjectModel\Task.cs (1)
49var task = new XElement("Task",