124 references to Elements
dotnet-svcutil-lib (6)
Shared\MSBuildProj.cs (4)
80IEnumerable<XElement> refItems = this.ProjectNode.Elements("ProjectReference"); 103IEnumerable<XElement> refItems = this.ProjectNode.Elements("Reference"); 127IEnumerable<XElement> refItems = this.ProjectNode.Elements("PackageReference"); 445IEnumerable<XElement> groups = projectElement.Elements(group);
Shared\Utilities\RuntimeEnvironmentHelper.cs (2)
86added = pkgSourcesNode.Elements("add")? 95while (pkgSourcesNode.Elements("add").Any(e => StringComparer.OrdinalIgnoreCase.Compare(e.Attribute("key").Value, feedName) == 0))
IIS.LongTests (1)
src\Servers\IIS\IIS\test\Common.LongTests\StartupTests.cs (1)
320.Elements("add")
IIS.NewHandler.FunctionalTests (1)
src\Servers\IIS\IIS\test\Common.LongTests\StartupTests.cs (1)
320.Elements("add")
IIS.NewShim.FunctionalTests (1)
src\Servers\IIS\IIS\test\Common.LongTests\StartupTests.cs (1)
320.Elements("add")
IISExpress.FunctionalTests (1)
src\Servers\IIS\IIS\test\Common.LongTests\StartupTests.cs (1)
320.Elements("add")
Microsoft.AspNetCore.Authentication.Test (27)
CertificateTests.cs (21)
480var actual = responseAsXml.Elements("claim").Where(claim => claim.Attribute("Type").Value == "issuer"); 484actual = responseAsXml.Elements("claim").Where(claim => claim.Attribute("Type").Value == ClaimTypes.Thumbprint); 491actual = responseAsXml.Elements("claim").Where(claim => claim.Attribute("Type").Value == ClaimTypes.X500DistinguishedName); 501actual = responseAsXml.Elements("claim").Where(claim => claim.Attribute("Type").Value == ClaimTypes.SerialNumber); 511actual = responseAsXml.Elements("claim").Where(claim => claim.Attribute("Type").Value == ClaimTypes.Dns); 521actual = responseAsXml.Elements("claim").Where(claim => claim.Attribute("Type").Value == ClaimTypes.Email); 531actual = responseAsXml.Elements("claim").Where(claim => claim.Attribute("Type").Value == ClaimTypes.Name); 541actual = responseAsXml.Elements("claim").Where(claim => claim.Attribute("Type").Value == ClaimTypes.Upn); 551actual = responseAsXml.Elements("claim").Where(claim => claim.Attribute("Type").Value == ClaimTypes.Uri); 609var name = responseAsXml.Elements("claim").Where(claim => claim.Attribute("Type").Value == ClaimTypes.Name); 612var count = responseAsXml.Elements("claim").Where(claim => claim.Attribute("Type").Value == "ValidationCount"); 628name = responseAsXml.Elements("claim").Where(claim => claim.Attribute("Type").Value == ClaimTypes.Name); 631count = responseAsXml.Elements("claim").Where(claim => claim.Attribute("Type").Value == "ValidationCount"); 679var actual = responseAsXml.Elements("claim").Where(claim => claim.Attribute("Type").Value == ClaimTypes.Name); 682Assert.Single(responseAsXml.Elements("claim")); 736var name = responseAsXml.Elements("claim").Where(claim => claim.Attribute("Type").Value == ClaimTypes.Name); 739var count = responseAsXml.Elements("claim").Where(claim => claim.Attribute("Type").Value == "ValidationCount"); 755name = responseAsXml.Elements("claim").Where(claim => claim.Attribute("Type").Value == ClaimTypes.Name); 758count = responseAsXml.Elements("claim").Where(claim => claim.Attribute("Type").Value == "ValidationCount"); 777name = responseAsXml.Elements("claim").Where(claim => claim.Attribute("Type").Value == ClaimTypes.Name); 780count = responseAsXml.Elements("claim").Where(claim => claim.Attribute("Type").Value == "ValidationCount");
CookieTests.cs (2)
1754var claim = transaction.ResponseElement.Elements("claim").SingleOrDefault(elt => elt.Attribute("type").Value == claimType); 1764var property = transaction.ResponseElement.Elements("extra").SingleOrDefault(elt => elt.Attribute("type").Value == key);
OpenIdConnect\TestSettings.cs (2)
62.Elements("input") 100.Elements("input")
Transaction.cs (2)
38var claim = ResponseElement.Elements("claim") 50var claim = ResponseElement.Elements("token")
Microsoft.AspNetCore.CookiePolicy.Test (1)
Transaction.cs (1)
39var claim = ResponseElement.Elements("claim")
Microsoft.AspNetCore.DataProtection (1)
AuthenticatedEncryption\ConfigurationModel\AuthenticatedEncryptorDescriptorDeserializer.cs (1)
43Secret masterKey = ((string)element.Elements("masterKey").Single()).ToSecret();
Microsoft.AspNetCore.Identity.InMemory.Test (1)
FunctionalTest.cs (1)
283var claim = transaction.ResponseElement.Elements("claim").SingleOrDefault(elt => elt.Attribute("type").Value == claimType);
Microsoft.AspNetCore.Mvc.FunctionalTests (1)
AsyncEnumerableTestBase.cs (1)
89var projects = xml.Root.Elements(XName.Get("Project", @namespace));
Microsoft.AspNetCore.Rewrite (4)
IISUrlRewrite\RewriteMapParser.cs (2)
22foreach (var mapElement in mapsElement.Elements(RewriteTags.RewriteMap)) 25foreach (var addElement in mapElement.Elements(RewriteTags.Add))
IISUrlRewrite\UrlRewriteFileParser.cs (2)
46foreach (var rule in rules.Elements(RewriteTags.Rule)) 113var adds = conditions.Elements(RewriteTags.Add);
Microsoft.AspNetCore.Server.IntegrationTesting (1)
Deployers\RemoteWindowsDeployer\RemoteWindowsDeployer.cs (1)
166var environmentVariablesSection = aspNetCoreSection.Elements("environmentVariables").FirstOrDefault();
Microsoft.AspNetCore.Server.IntegrationTesting.IIS (1)
XElementExtensions.cs (1)
35var existing = element.Elements(name).FirstOrDefault(e => e.Attribute(attribute)?.Value == attributeValue);
Microsoft.Build.BuildCheck.UnitTests (1)
TestAssemblyInfo.cs (1)
121var cliVersionElement = doc.Root.Elements(ns + "PropertyGroup").Elements(ns + "DotNetCliVersion").FirstOrDefault();
Microsoft.Build.CommandLine.UnitTests (1)
TestAssemblyInfo.cs (1)
121var cliVersionElement = doc.Root.Elements(ns + "PropertyGroup").Elements(ns + "DotNetCliVersion").FirstOrDefault();
Microsoft.Build.Engine.OM.UnitTests (1)
TestAssemblyInfo.cs (1)
121var cliVersionElement = doc.Root.Elements(ns + "PropertyGroup").Elements(ns + "DotNetCliVersion").FirstOrDefault();
Microsoft.Build.Engine.UnitTests (1)
TestAssemblyInfo.cs (1)
121var cliVersionElement = doc.Root.Elements(ns + "PropertyGroup").Elements(ns + "DotNetCliVersion").FirstOrDefault();
Microsoft.Build.Framework.UnitTests (1)
TestAssemblyInfo.cs (1)
121var cliVersionElement = doc.Root.Elements(ns + "PropertyGroup").Elements(ns + "DotNetCliVersion").FirstOrDefault();
Microsoft.Build.Tasks.Core (1)
GenerateResource.cs (1)
3063foreach (XElement dataElem in doc.Element("root").Elements("data"))
Microsoft.Build.Tasks.UnitTests (1)
TestAssemblyInfo.cs (1)
121var cliVersionElement = doc.Root.Elements(ns + "PropertyGroup").Elements(ns + "DotNetCliVersion").FirstOrDefault();
Microsoft.Build.Utilities.UnitTests (1)
TestAssemblyInfo.cs (1)
121var cliVersionElement = doc.Root.Elements(ns + "PropertyGroup").Elements(ns + "DotNetCliVersion").FirstOrDefault();
Microsoft.CodeAnalysis (1)
RuleSet\RuleSetProcessor.cs (1)
81List<XElement> nodeList = ruleSetDocument.Elements(RuleSetNodeName).ToList();
Microsoft.CodeAnalysis.CodeStyle (8)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\NamingStylePreferences.cs (3)
333element.Element("SymbolSpecifications").Elements(nameof(SymbolSpecification)) 335element.Element("NamingStyles").Elements(nameof(NamingStyle)) 337element.Element("NamingRules").Elements(nameof(SerializableNamingRule))
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SymbolSpecification.cs (5)
293foreach (var symbolKindElement in symbolKindListElement.Elements(nameof(SymbolKind))) 298foreach (var typeKindElement in symbolKindListElement.Elements(nameof(TypeKind))) 303foreach (var methodKindElement in symbolKindListElement.Elements(nameof(MethodKind))) 312=> accessibilityListElement.Elements("AccessibilityKind").SelectAsArray(ParseAccessibility); 318=> modifierListElement.Elements(nameof(ModifierKind)).SelectAsArray(ModifierKind.FromXElement);
Microsoft.CodeAnalysis.CSharp.EditorFeatures2.UnitTests (1)
EmbeddedLanguages\Json\CSharpJsonParserTests.cs (1)
94foreach (var diagnosticElement in diagnosticsElement.Elements("Diagnostic"))
Microsoft.CodeAnalysis.Workspaces (8)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\NamingStylePreferences.cs (3)
333element.Element("SymbolSpecifications").Elements(nameof(SymbolSpecification)) 335element.Element("NamingStyles").Elements(nameof(NamingStyle)) 337element.Element("NamingRules").Elements(nameof(SerializableNamingRule))
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SymbolSpecification.cs (5)
293foreach (var symbolKindElement in symbolKindListElement.Elements(nameof(SymbolKind))) 298foreach (var typeKindElement in symbolKindListElement.Elements(nameof(TypeKind))) 303foreach (var methodKindElement in symbolKindListElement.Elements(nameof(MethodKind))) 312=> accessibilityListElement.Elements("AccessibilityKind").SelectAsArray(ParseAccessibility); 318=> modifierListElement.Elements(nameof(ModifierKind)).SelectAsArray(ModifierKind.FromXElement);
Microsoft.CodeAnalysis.Workspaces.MSBuild (2)
MSBuild\BuildHostProcessManager.cs (2)
331if (document.Root.Elements("Import").Attributes("Sdk").Any()) 335if (document.Root.Elements("Sdk").Any())
Microsoft.CodeAnalysis.Workspaces.MSBuild.UnitTests (1)
VisualStudioMSBuildWorkspaceTests.cs (1)
2511r => r.Elements(XName.Get("Project", MSBuildNamespace)).Remove());
Microsoft.CodeAnalysis.Workspaces.Test.Utilities (15)
Workspaces\TestWorkspace_XmlConsumption.cs (11)
162var documentElements = projectElement.Elements(DocumentElementName).ToList(); 177foreach (var sourceGeneratedDocumentElement in projectElement.Elements(DocumentFromSourceGeneratorElementName)) 201var additionalDocumentElements = projectElement.Elements(AdditionalDocumentElementName).ToList(); 216var analyzerConfigElements = projectElement.Elements(AnalyzerConfigDocumentElementName).ToList(); 421globalImports = compilationOptionsElement.Elements(GlobalImportElementName) 566var originalProject = workspaceElement.Elements(ProjectElementName).FirstOrDefault(p => 597documentElement = originalProject.Elements(DocumentElementName).FirstOrDefault(d => 772var documentElements = referencedSource.Elements(DocumentElementName).ToList(); 805foreach (var reference in element.Elements(MetadataReferenceElementName)) 815foreach (var metadataReferenceFromSource in element.Elements(MetadataReferenceFromSourceElementName)) 826foreach (var analyzer in projectElement.Elements(AnalyzerElementName))
Workspaces\TestWorkspace`1.cs (4)
643foreach (var projectElement in workspaceElement.Elements(ProjectElementName)) 670var submissions = CreateSubmissions(workspaceElement.Elements(SubmissionElementName), ExportProvider); 681foreach (var projectElement in workspaceElement.Elements(ProjectElementName)) 683foreach (var projectReference in projectElement.Elements(ProjectReferenceElementName))
Microsoft.DotNet.Arcade.Sdk (4)
src\ExtractNgenMethodList.cs (1)
58foreach (var child in parentElement.Elements("Item"))
src\GenerateResxSource.cs (1)
115string value = node.Elements("value").FirstOrDefault()?.Value.Trim();
src\SourceBuild\AddSourceToNuGetConfig.cs (2)
49.Elements(CreateQualifiedName("add")) 53.Elements(CreateQualifiedName("clear"))
Microsoft.DotNet.Build.Tasks.Installers (4)
src\StabilizeWixFileId.cs (4)
68.Elements(GetQualifiedName("Fragment")) 69.SelectMany(f => f.Elements(GetQualifiedName("ComponentGroup"))) 70.SelectMany(cg => cg.Elements(GetQualifiedName("Component"))) 71.SelectMany(c => c.Elements(GetQualifiedName("File")))
Microsoft.DotNet.Build.Tasks.Packaging (1)
PackageIndex.cs (1)
217foreach (var file in frameworkList.Element("FileList").Elements("File"))
Microsoft.DotNet.MacOsPkg (1)
Package.cs (1)
57List<XElement> componentPackages = xml.Elements("pkg-ref").Where(e => e.Value.Trim() != "").ToList();
Microsoft.DotNet.NuGetRepack.Tasks (1)
src\NuGetVersionUpdater.cs (1)
269foreach (var packageType in packageTypesElement.Elements(XName.Get("packageType", nuspecXmlns)) ?? Array.Empty<XElement>())
Microsoft.DotNet.VersionTools (9)
BuildManifest\Model\ArtifactSet.cs (2)
34Packages = xml.Elements("Package").Select(PackageArtifactModel.Parse).ToList(), 35Blobs = xml.Elements("Blob").Select(BlobArtifactModel.Parse).ToList(),
BuildManifest\Model\OrchestratedBuildModel.cs (2)
50Endpoints = xml.Elements("Endpoint").Select(EndpointModel.Parse).ToList(), 51Builds = xml.Elements("Build").Select(BuildIdentity.Parse).ToList()
BuildManifest\Model\SigningInformationModel.cs (5)
67FileExtensionSignInfo = xml.Elements("FileExtensionSignInfo").Select(FileExtensionSignInfoModel.Parse) 69FileSignInfo = xml.Elements("FileSignInfo").Select(FileSignInfoModel.Parse) 71ItemsToSign = xml.Elements("ItemsToSign").Select(ItemToSignModel.Parse).ToList(), 72StrongNameSignInfo = xml.Elements("StrongNameSignInfo").Select(StrongNameSignInfoModel.Parse) 74CertificatesSignInfo = xml.Elements("CertificatesSignInfo").Select(CertificatesSignInfoModel.Parse)
Microsoft.DotNet.XliffTasks (7)
Model\XamlRuleDocument.cs (5)
30var descendentDisplayName = element.Elements(XName.Get($"{element.Name.LocalName}.DisplayName", element.Name.NamespaceName)).FirstOrDefault(); 31var descendentDescription = element.Elements(XName.Get($"{element.Name.LocalName}.Description", element.Name.NamespaceName)).FirstOrDefault(); 60if (element.Elements(XName.Get($"{element.Name.LocalName}.{localizableProperty}", element.Name.NamespaceName)).FirstOrDefault() is { } descendentValue) 82else if (AttributedName(element) == "SearchTerms" && (XmlName(attribute) == "Value" || element.Elements(XName.Get($"{element.Name.LocalName}.Value", element.Name.NamespaceName)).FirstOrDefault() is { })) 93else if (element.Elements(XName.Get($"{element.Name.LocalName}.Value", element.Name.NamespaceName)).FirstOrDefault() is { } descendentValue)
Model\XlfDocument.cs (2)
195foreach (XElement transUnit in bodyElement.Elements(TransUnit)) 229IEnumerable<XElement> transUnits = bodyElement.Elements(TransUnit);
Microsoft.Maui.Resizetizer (3)
GeneratePackageAppxManifest.cs (1)
318 var showons = showname.Elements(xshowon).ToArray();
GenerateTizenManifest.cs (2)
140 var iconElements = uiApplicationElement.Elements(xiconName); 171 var splashElements = splashscreensElement.Elements(xmlns + SplashScreenName).Where(
Microsoft.VisualStudio.LanguageServices (1)
Snippets\SnippetExpansionClient.cs (1)
1093foreach (var reference in referencesNode.Elements(XName.Get("Reference", snippetNode.Name.NamespaceName)))
Microsoft.VisualStudio.LanguageServices.CSharp (1)
Snippets\CSharpSnippetExpansionLanguageHelper.cs (1)
115foreach (var import in importsNode.Elements(XName.Get("Import", snippetNode.Name.NamespaceName)))
System.ComponentModel.TypeConverter (1)
MS\Internal\Xml\Linq\ComponentModel\XComponentModel.cs (1)
328return _value = new XDeferredAxis<XElement>((e, n) => n != null ? e.Elements(n) : e.Elements(), (component as XElement)!, null);