18 writes to Value
IIS.FunctionalTests (1)
src\Servers\IIS\IIS\test\Common.FunctionalTests\GlobalVersionTests.cs (1)
251imageAttribute.Value = imageAttribute.Value.Replace(sourceDirectory.FullName, destinationDirectory.FullName);
IISExpress.FunctionalTests (1)
src\Servers\IIS\IIS\test\Common.FunctionalTests\GlobalVersionTests.cs (1)
251imageAttribute.Value = imageAttribute.Value.Replace(sourceDirectory.FullName, destinationDirectory.FullName);
Microsoft.Build.Tasks.Core (2)
AssemblyDependency\GenerateBindingRedirects.cs (2)
311oldVersionAttribute.Value = "0.0.0.0-" + (maxVersion >= oldVersionHigh ? maxVerStr : oldVerStrHigh); 312newVersionAttribute.Value = maxVerStr;
Microsoft.CodeAnalysis.CSharp (1)
Compiler\DocumentationCommentCompiler.IncludeElementExpander.cs (1)
519attribute.Value = GetDocumentationCommentId(crefSyntax, binder, crefDiagnostics); // NOTE: mutation (element must be a copy)
Microsoft.CodeAnalysis.Features.Test.Utilities (1)
Options\NamingStyleTestUtilities.cs (1)
63attribute.Value = existingOrdinal.ToString();
Microsoft.CodeAnalysis.VisualBasic (4)
Compilation\DocumentationComments\DocumentationCommentCompiler.Includes.vb (4)
641attribute.Value = "?:" + attribute.Value 679attribute.Value = "?:" + attribute.Value 683attribute.Value = symbolCommentId 704attribute.Value = "?:" + value
Microsoft.DotNet.Build.Tasks.Installers (1)
src\StabilizeWixFileId.cs (1)
97nameAttribute.Value = replacement;
Microsoft.DotNet.XliffTasks (4)
Model\TranslatableXmlDocument.cs (1)
55_attribute.Value = translation;
Model\VsctDocument.cs (1)
89imageTag.Attribute("href").Value = absolutePath;
Model\XElementExtensions.cs (1)
81stateAttribute.Value = value;
Model\XlfDocument.cs (1)
94originalAttribute.Value = sourceDocumentId;
System.ComponentModel.TypeConverter (1)
MS\Internal\Xml\Linq\ComponentModel\XComponentModel.cs (1)
483_attribute.Value = (value as string)!;
System.Private.Xml.Linq (2)
System\Xml\Linq\XAttribute.cs (1)
203Value = XContainer.GetStringValue(value);
System\Xml\Linq\XElement.cs (1)
1226a.Value = GetStringValue(value);
379 references to Value
BuildBoss (7)
ProjectUtil.cs (7)
107.Select(x => x.Attribute("Project")?.Value) 120var referenceOutputAssemblyValue = r.Element(Namespace.GetName("ReferenceOutputAssembly"))?.Value ?? r.Attribute(XName.Get("ReferenceOutputAssembly"))?.Value; 136var relativePath = r.Attribute("Include").Value; 157var targetAssembly = element.Attribute("Include")?.Value.Trim(); 158var key = element.Attribute("Key")?.Value.Trim(); 159var loadsWithinVisualStudio = element.Attribute("LoadsWithinVisualStudio")?.Value.Trim(); 160var workItem = element.Attribute("WorkItem")?.Value.Trim();
ConfigurationSchemaGenerator (1)
ConfigSchemaEmitter.cs (1)
557var attributeValue = element.FirstAttribute!.Value;
dotnet-svcutil-lib (5)
Shared\MSBuildProj.cs (3)
472return itemAttribue.Value; 495itemIdentity = itemAttribute.Value; 508return itemAttribute.Value;
Shared\Utilities\RuntimeEnvironmentHelper.cs (2)
87.Select(e => e.Attribute("value").Value.TrimEnd(Path.DirectorySeparatorChar)) 95while (pkgSourcesNode.Elements("add").Any(e => StringComparer.OrdinalIgnoreCase.Compare(e.Attribute("key").Value, feedName) == 0))
IIS.FunctionalTests (5)
src\Servers\IIS\IIS\test\Common.FunctionalTests\FrebTests.cs (1)
158var requestStatus = eventElement.Element(nameSpace + "EventData").Descendants().Where(el => el.Attribute("Name").Value == "requestStatus").SingleOrDefault();
src\Servers\IIS\IIS\test\Common.FunctionalTests\GlobalVersionTests.cs (3)
242element.Attribute("name")?.Value.StartsWith("AspNetCoreModule", StringComparison.Ordinal) == true && 245var sourceDirectory = new DirectoryInfo(Path.GetDirectoryName(moduleNodes.First().Attribute("image").Value)); 251imageAttribute.Value = imageAttribute.Value.Replace(sourceDirectory.FullName, destinationDirectory.FullName);
src\Servers\IIS\IIS\test\Common.FunctionalTests\Infrastructure\RequiresIISAttribute.cs (1)
89.Any(n => "hostingModel".Equals(n.Attribute("name")?.Value, StringComparison.Ordinal));
IIS.LongTests (3)
src\Servers\IIS\IIS\test\Common.FunctionalTests\Infrastructure\RequiresIISAttribute.cs (1)
89.Any(n => "hostingModel".Equals(n.Attribute("name")?.Value, StringComparison.Ordinal));
src\Servers\IIS\IIS\test\Common.LongTests\StartupTests.cs (2)
321.FirstOrDefault(e => e.Attribute("name").Value == "AspNetCoreModuleV2"); 323ancmElement.SetAttributeValue("image", ancmElement.Attribute("image").Value.Replace("x64", "x86"));
IIS.NewHandler.FunctionalTests (3)
src\Servers\IIS\IIS\test\Common.FunctionalTests\Infrastructure\RequiresIISAttribute.cs (1)
89.Any(n => "hostingModel".Equals(n.Attribute("name")?.Value, StringComparison.Ordinal));
src\Servers\IIS\IIS\test\Common.LongTests\StartupTests.cs (2)
321.FirstOrDefault(e => e.Attribute("name").Value == "AspNetCoreModuleV2"); 323ancmElement.SetAttributeValue("image", ancmElement.Attribute("image").Value.Replace("x64", "x86"));
IIS.NewShim.FunctionalTests (3)
src\Servers\IIS\IIS\test\Common.FunctionalTests\Infrastructure\RequiresIISAttribute.cs (1)
89.Any(n => "hostingModel".Equals(n.Attribute("name")?.Value, StringComparison.Ordinal));
src\Servers\IIS\IIS\test\Common.LongTests\StartupTests.cs (2)
321.FirstOrDefault(e => e.Attribute("name").Value == "AspNetCoreModuleV2"); 323ancmElement.SetAttributeValue("image", ancmElement.Attribute("image").Value.Replace("x64", "x86"));
IIS.ShadowCopy.Tests (1)
src\Servers\IIS\IIS\test\Common.FunctionalTests\Infrastructure\RequiresIISAttribute.cs (1)
89.Any(n => "hostingModel".Equals(n.Attribute("name")?.Value, StringComparison.Ordinal));
IISExpress.FunctionalTests (6)
src\Servers\IIS\IIS\test\Common.FunctionalTests\FrebTests.cs (1)
158var requestStatus = eventElement.Element(nameSpace + "EventData").Descendants().Where(el => el.Attribute("Name").Value == "requestStatus").SingleOrDefault();
src\Servers\IIS\IIS\test\Common.FunctionalTests\GlobalVersionTests.cs (3)
242element.Attribute("name")?.Value.StartsWith("AspNetCoreModule", StringComparison.Ordinal) == true && 245var sourceDirectory = new DirectoryInfo(Path.GetDirectoryName(moduleNodes.First().Attribute("image").Value)); 251imageAttribute.Value = imageAttribute.Value.Replace(sourceDirectory.FullName, destinationDirectory.FullName);
src\Servers\IIS\IIS\test\Common.LongTests\StartupTests.cs (2)
321.FirstOrDefault(e => e.Attribute("name").Value == "AspNetCoreModuleV2"); 323ancmElement.SetAttributeValue("image", ancmElement.Attribute("image").Value.Replace("x64", "x86"));
Microsoft.AspNetCore.App.UnitTests (18)
SharedFxTests.cs (7)
272_output.WriteLine(string.Join('\n', runtimeListEntries.Select(i => i.Attribute("Path").Value).OrderBy(i => i))); 279var filePath = i.Attribute("Path").Value; 301var assemblyType = i.Attribute("Type").Value; 302var assemblyPath = i.Attribute("Path").Value; 303var fileVersion = i.Attribute("FileVersion").Value; 307var assemblyVersion = i.Attribute("AssemblyVersion").Value; 336var expectedPaths = runtimeListEntries.Select(i => i.Attribute("Path").Value).ToHashSet();
TargetingPackTests.cs (11)
301var managedEntries = frameworkListEntries.Where(i => i.Attribute("Type").Value.Equals("Managed", StringComparison.Ordinal)); 302var analyzerEntries = frameworkListEntries.Where(i => i.Attribute("Type").Value.Equals("Analyzer", StringComparison.Ordinal)); 318_output.WriteLine(string.Join('\n', actualElements.Select(i => i.Attribute("AssemblyName").Value).OrderBy(i => i))); 325var fileName = i.Attribute("AssemblyName").Value; 346var assemblyPath = i.Attribute("Path").Value; 347var assemblyVersion = i.Attribute("AssemblyVersion").Value; 348var fileVersion = i.Attribute("FileVersion").Value; 378var expectedPaths = frameworkListEntries.Select(i => i.Attribute("Path").Value).ToHashSet(); 407var analyzerEntries = frameworkListEntries.Where(i => i.Attribute("Type").Value.Equals("Analyzer", StringComparison.Ordinal)); 411var actualLanguage = analyzerEntry.Attribute("Language")?.Value; 412var assemblyPath = analyzerEntry.Attribute("Path").Value;
Microsoft.AspNetCore.Authentication.Test (33)
CertificateTests.cs (20)
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); 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 (4)
1754var claim = transaction.ResponseElement.Elements("claim").SingleOrDefault(elt => elt.Attribute("type").Value == claimType); 1759return claim.Attribute("value").Value; 1764var property = transaction.ResponseElement.Elements("extra").SingleOrDefault(elt => elt.Attribute("type").Value == key); 1769return property.Attribute("value").Value;
OpenIdConnect\TestSettings.cs (4)
63.ToDictionary(elem => elem.Attribute("name").Value, 64elem => elem.Attribute("value").Value); 101.ToDictionary(elem => elem.Attribute("name").Value, 102elem => elem.Attribute("value").Value);
Transaction.cs (5)
39.SingleOrDefault(elt => elt.Attribute("type").Value == claimType && 40(issuer == null || elt.Attribute("issuer").Value == issuer)); 45return claim.Attribute("value").Value; 51.SingleOrDefault(elt => elt.Attribute("name").Value == name); 56return claim.Attribute("value").Value;
Microsoft.AspNetCore.CookiePolicy.Test (3)
Transaction.cs (3)
40.SingleOrDefault(elt => elt.Attribute("type").Value == claimType && 41(issuer == null || elt.Attribute("issuer").Value == issuer)); 46return claim.Attribute("value").Value;
Microsoft.AspNetCore.DataProtection (1)
XmlExtensions.cs (1)
24newElement.SetAttributeValue(attr.Name, attr.Value);
Microsoft.AspNetCore.DataProtection.Tests (2)
XmlAssert.cs (2)
101&& expected.Value == actual.Value;
Microsoft.AspNetCore.Identity.InMemory.Test (2)
FunctionalTest.cs (2)
283var claim = transaction.ResponseElement.Elements("claim").SingleOrDefault(elt => elt.Attribute("type").Value == claimType); 288return claim.Attribute("value").Value;
Microsoft.AspNetCore.Rewrite (16)
IISUrlRewrite\RewriteMapParser.cs (3)
24var map = new IISRewriteMap(mapElement.Attribute(RewriteTags.Name)?.Value!); 27map[addElement.Attribute(RewriteTags.Key)!.Value.ToLowerInvariant()] = addElement.Attribute(RewriteTags.Value)!.Value;
IISUrlRewrite\UrlRewriteFileParser.cs (13)
60builder.Name = rule.Attribute(RewriteTags.Name)?.Value; 93var parsedInputString = match.Attribute(RewriteTags.Url)?.Value; 132var parsedInputString = conditionElement.Attribute(RewriteTags.Input)?.Value; 139var parsedPatternString = conditionElement.Attribute(RewriteTags.Pattern)?.Value; 202url = urlAction.Attribute(RewriteTags.Url)!.Value; 227if (!int.TryParse(urlAction.Attribute(RewriteTags.StatusCode)?.Value, NumberStyles.None, CultureInfo.InvariantCulture, out statusCode)) 237if (!string.IsNullOrEmpty(urlAction.Attribute(RewriteTags.SubStatusCode)?.Value)) 242var statusReason = urlAction.Attribute(RewriteTags.StatusReason)?.Value; 243var statusDescription = urlAction.Attribute(RewriteTags.StatusDescription)?.Value; 261else if (!bool.TryParse(attribute.Value, out result)) 263throw new InvalidUrlRewriteFormatException(element, $"The {rewriteTag} parameter '{attribute.Value}' was not recognized"); 277else if (!Enum.TryParse(attribute.Value, ignoreCase: true, result: out enumResult)) 279throw new InvalidUrlRewriteFormatException(element, $"The {rewriteTag} parameter '{attribute.Value}' was not recognized");
Microsoft.AspNetCore.Server.IntegrationTesting (1)
xunit\IISExpressAncmSchema.cs (1)
46.Any(n => "hostingModel".Equals(n.Attribute("name")?.Value, StringComparison.Ordinal));
Microsoft.AspNetCore.Server.IntegrationTesting.IIS (2)
IISDeployer.cs (1)
143if (aspNetCore.Attribute("processPath")?.Value.StartsWith("dotnet", StringComparison.Ordinal) == true)
XElementExtensions.cs (1)
35var existing = element.Elements(name).FirstOrDefault(e => e.Attribute(attribute)?.Value == attributeValue);
Microsoft.Build.Tasks.Core (25)
AssemblyDependency\GenerateBindingRedirects.cs (4)
243var nameValue = name.Value; 244var publicKeyTokenValue = publicKeyToken.Value; 246var cultureValue = culture?.Value ?? String.Empty; 256var oldVersionRange = oldVersionAttribute.Value.Split(MSBuildConstants.HyphenChar);
GenerateResource.cs (1)
3065string name = dataElem.Attribute("name").Value;
ResourceHandling\MSBuildResXReader.cs (6)
58string alias = elem.Attribute("alias")?.Value; 59string name = elem.Attribute("name").Value; 114string name = elem.Attribute("name").Value; 116bool preserve = elem.Attribute(XName.Get("space", "http://www.w3.org/XML/1998/namespace"))?.Value == "preserve"; 137string typename = elem.Attribute("type")?.Value; 138string mimetype = elem.Attribute("mimetype")?.Value;
RoslynCodeTaskFactory\RoslynCodeTaskFactory.cs (14)
350if (String.IsNullOrWhiteSpace(includeAttribute?.Value)) 358taskInfo.References.Add(includeAttribute.Value.Trim()); 364if (String.IsNullOrWhiteSpace(namespaceAttribute?.Value)) 372taskInfo.Namespaces.Add(namespaceAttribute.Value.Trim()); 434if (String.IsNullOrWhiteSpace(sourceAttribute.Value)) 443taskInfo.SourceCode = File.ReadAllText(sourceAttribute.Value.Trim()); 448if (String.IsNullOrWhiteSpace(typeAttribute.Value)) 456if (!Enum.TryParse(typeAttribute.Value.Trim(), ignoreCase: true, result: out RoslynCodeTaskFactoryCodeType codeType)) 458log.LogErrorWithCodeFromResources("CodeTaskFactory.InvalidCodeType", typeAttribute.Value, String.Join(", ", Enum.GetNames(typeof(RoslynCodeTaskFactoryCodeType)))); 467if (String.IsNullOrWhiteSpace(languageAttribute.Value)) 474if (ValidCodeLanguages.ContainsKey(languageAttribute.Value)) 477taskInfo.CodeLanguage = languageAttribute.Value.ToUpperInvariant(); 486if (validLanguage.Value.Contains(languageAttribute.Value)) 497log.LogErrorWithCodeFromResources("CodeTaskFactory.InvalidCodeLanguage", languageAttribute.Value, String.Join(", ", ValidCodeLanguages.Keys));
Microsoft.CodeAnalysis (3)
RuleSet\RuleSetProcessor.cs (3)
261if (string.IsNullOrEmpty(attribute.Value)) 263throw new InvalidRuleSetException(string.Format(CodeAnalysisResources.RuleSetBadAttributeValue, attributeName, attribute.Value)); 266return attribute.Value;
Microsoft.CodeAnalysis.CodeStyle (15)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleOption2`1.cs (3)
186var parser = GetParser(typeAttribute.Value); 187var value = parser(valueAttribute.Value); 188var severity = (DiagnosticSeverity)Enum.Parse(typeof(DiagnosticSeverity), severityAttribute.Value);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (6)
474id: Guid.Parse(namingStyleElement.Attribute(nameof(ID)).Value), 475name: namingStyleElement.Attribute(nameof(Name)).Value, 476prefix: namingStyleElement.Attribute(nameof(Prefix)).Value, 477suffix: namingStyleElement.Attribute(nameof(Suffix)).Value, 478wordSeparator: namingStyleElement.Attribute(nameof(WordSeparator)).Value, 479capitalizationScheme: (Capitalization)Enum.Parse(typeof(Capitalization), namingStyleElement.Attribute(nameof(CapitalizationScheme)).Value));
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\NamingStylePreferences.cs (1)
380var serializationVersion = int.Parse(rootElement.Attribute("SerializationVersion").Value);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SerializableNamingRule.cs (3)
46EnforcementLevel = ((DiagnosticSeverity)Enum.Parse(typeof(DiagnosticSeverity), namingRuleElement.Attribute(nameof(EnforcementLevel))!.Value)).ToReportDiagnostic(), 47NamingStyleID = Guid.Parse(namingRuleElement.Attribute(nameof(NamingStyleID))!.Value), 48SymbolSpecificationID = Guid.Parse(namingRuleElement.Attribute(nameof(SymbolSpecificationID))!.Value)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SymbolSpecification.cs (2)
284id: Guid.Parse(symbolSpecificationElement.Attribute(nameof(ID)).Value), 285name: symbolSpecificationElement.Attribute(nameof(Name)).Value,
Microsoft.CodeAnalysis.CSharp (5)
Compiler\DocumentationCommentCompiler.IncludeElementExpander.cs (5)
278string filePathValue = fileAttr.Value; 279string xpathValue = pathAttr.Value; 309string xpathValue = pathAttr.Value; 310string filePathValue = fileAttr.Value; 497string attributeValue = attribute.Value;
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (3)
DocumentationComments\CrefTests.cs (2)
6924var cref = xml.Descendants("see").Single().Attribute("cref").Value; 6948var cref = xml.Descendants("see").Single().Attribute("cref").Value;
Symbols\MockSymbolTests.cs (1)
109string name = xel.Attribute("name").Value;
Microsoft.CodeAnalysis.Features (11)
DocumentationComments\AbstractDocumentationCommentFormattingService.cs (8)
390var rawListType = element.Attribute(DocumentationCommentXmlNames.TypeAttributeName)?.Value; 453var symbol = DocumentationCommentId.GetFirstSymbolForDeclarationId(crefAttribute.Value, semanticModel.Compilation); 460return (target: hrefAttribute.Value, hint: hrefAttribute.Value); 473TypeParameterRefToSymbolDisplayParts(attribute.Value, state.TypeResolutionSymbol, state.Position, state.SemanticModel, state.Format).ToTaggedText(state.Style)); 478CrefToSymbolDisplayParts(attribute.Value, state.Position, state.SemanticModel, state.Format, kind).ToTaggedText(state.Style)); 486var text = attribute.Value; 489? attribute.Value
SymbolSearch\Windows\SymbolSearchUpdateEngine.Update.cs (3)
548var contents = contentsAttribute.Value; 702var expectedChecksum = checksumAttribute.Value; 722var text = contentsAttribute.Value;
Microsoft.CodeAnalysis.Features.Test.Utilities (1)
Options\NamingStyleTestUtilities.cs (1)
55if (Guid.TryParse(attribute.Value, out var guid))
Microsoft.CodeAnalysis.LanguageServer.Protocol (3)
Handler\InlineCompletions\XmlSnippetParser.CodeSnippet.cs (3)
147_delimiter = delimiterAttribute.Value; 168editableAttribute == null || string.Equals(editableAttribute.Value, "true", StringComparison.Ordinal) || string.Equals(editableAttribute.Value, "1", StringComparison.Ordinal)));
Microsoft.CodeAnalysis.Test.Utilities (19)
Assert\AssertXml.cs (1)
266return new Tuple<XName, string>(attribute.Name, attribute.Value);
Metadata\ILValidation.cs (18)
333let xmlTokenValue = e.Attribute("token")?.Value 342.Descendants().ToImmutableDictionary(e => e.Attribute("id").Value, e => e.Attribute("name").Value); 355add(Convert.ToInt32(e.Attribute("offset").Value, 16), (e.Attribute("hidden")?.Value == "true") ? "~" : "-"); 363add(Convert.ToInt32(e.Attribute("yield").Value, 16), "<"); 364add(Convert.ToInt32(e.Attribute("resume").Value, 16), ">"); 368add(Convert.ToInt32(e.Attribute("offset").Value, 16), "$"); 386add(Convert.ToInt32(e.Attribute("yield").Value, 16), "async: yield"); 387add(Convert.ToInt32(e.Attribute("resume").Value, 16), "async: resume"); 391add(Convert.ToInt32(e.Attribute("offset").Value, 16), "async: catch handler"); 399var documentId = e.Attribute("document").Value; 402add(Convert.ToInt32(e.Attribute("offset").Value, 16), "sequence point: " + SnippetFromSpan(source, e)); 411if (sequencePointXml.Attribute("hidden")?.Value == "true") 416var startLine = Convert.ToInt32(sequencePointXml.Attribute("startLine").Value) - 1; 417var startColumn = Convert.ToInt32(sequencePointXml.Attribute("startColumn").Value) - 1; 418var endLine = Convert.ToInt32(sequencePointXml.Attribute("endLine").Value) - 1; 419var endColumn = Convert.ToInt32(sequencePointXml.Attribute("endColumn").Value) - 1;
Microsoft.CodeAnalysis.VisualBasic (8)
Compilation\DocumentationComments\DocumentationCommentCompiler.Includes.vb (8)
451commentMessage = GenerateDiagnostic(location, ERRID.WRN_XMLDocInvalidXMLFragment, fileAttr.Value, pathAttr.Value) 478Dim xpathValue As String = pathAttr.Value 479Dim filePathValue As String = fileAttr.Value 641attribute.Value = "?:" + attribute.Value 679attribute.Value = "?:" + attribute.Value 698Dim value As String = attribute.Value.Trim() 746Dim attributeValue As String = attribute.Value.Trim()
Microsoft.CodeAnalysis.Workspaces (20)
Shared\Extensions\ISymbolExtensions.cs (4)
369var crefValue = crefAttribute.Value; 394if (string.IsNullOrEmpty(pathAttribute?.Value)) 400xpathValue = pathAttribute!.Value; 431var index = symbol.OriginalDefinition.GetAllTypeParameters().IndexOf(p => p.Name == typeParamName.Value);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleOption2`1.cs (3)
186var parser = GetParser(typeAttribute.Value); 187var value = parser(valueAttribute.Value); 188var severity = (DiagnosticSeverity)Enum.Parse(typeof(DiagnosticSeverity), severityAttribute.Value);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\NamingStyle.cs (6)
474id: Guid.Parse(namingStyleElement.Attribute(nameof(ID)).Value), 475name: namingStyleElement.Attribute(nameof(Name)).Value, 476prefix: namingStyleElement.Attribute(nameof(Prefix)).Value, 477suffix: namingStyleElement.Attribute(nameof(Suffix)).Value, 478wordSeparator: namingStyleElement.Attribute(nameof(WordSeparator)).Value, 479capitalizationScheme: (Capitalization)Enum.Parse(typeof(Capitalization), namingStyleElement.Attribute(nameof(CapitalizationScheme)).Value));
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\NamingStylePreferences.cs (1)
380var serializationVersion = int.Parse(rootElement.Attribute("SerializationVersion").Value);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SerializableNamingRule.cs (3)
46EnforcementLevel = ((DiagnosticSeverity)Enum.Parse(typeof(DiagnosticSeverity), namingRuleElement.Attribute(nameof(EnforcementLevel))!.Value)).ToReportDiagnostic(), 47NamingStyleID = Guid.Parse(namingRuleElement.Attribute(nameof(NamingStyleID))!.Value), 48SymbolSpecificationID = Guid.Parse(namingRuleElement.Attribute(nameof(SymbolSpecificationID))!.Value)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SymbolSpecification.cs (2)
284id: Guid.Parse(symbolSpecificationElement.Attribute(nameof(ID)).Value), 285name: symbolSpecificationElement.Attribute(nameof(Name)).Value,
Utilities\Documentation\XmlDocumentationProvider.cs (1)
80comments[e.Attribute("name").Value] = e.ToString();
Microsoft.CodeAnalysis.Workspaces.Test.Utilities (27)
Workspaces\TestWorkspace_XmlConsumption.cs (26)
132var projectName = projectElement.Attribute(ProjectNameAttribute)?.Value ?? assemblyName; 136projectFilePath = projectElement.Attribute(FilePathAttributeName).Value; 278return new CSharpParseOptions(preprocessorSymbols: preprocessorSymbolsAttribute.Value.Split(',')); 282return new VisualBasicParseOptions(preprocessorSymbols: preprocessorSymbolsAttribute.Value 293var entries = featuresAttribute.Value.Split(';'); 311if (CodeAnalysis.CSharp.LanguageVersionFacts.TryParse(languageVersionAttribute.Value, out var languageVersion)) 319if (CodeAnalysis.VisualBasic.LanguageVersionFacts.TryParse(languageVersionAttribute.Value, ref languageVersion)) 333return (DocumentationMode)Enum.Parse(typeof(DocumentationMode), documentationModeAttribute.Value); 346return assemblyNameAttribute.Value; 365var languageName = languageAttribute.Value; 392return rootNamespaceAttribute?.Value ?? string.Empty; 426rootNamespace = rootNamespaceAttribute.Value; 432outputKind = (OutputKind)Enum.Parse(typeof(OutputKind), outputKindAttribute.Value); 485nullable = (NullableContextOptions)Enum.Parse(typeof(NullableContextOptions), nullableAttribute.Value); 490&& outputTypeAttribute.Value == "WindowsRuntimeMetadata") 558var originalAssemblyName = documentElement.Attribute(LinkAssemblyNameAttributeName)?.Value; 559var originalProjectName = documentElement.Attribute(LinkProjectNameAttributeName)?.Value; 570return p.Attribute(AssemblyNameAttributeName)?.Value == originalAssemblyName; 574return p.Attribute(ProjectNameAttribute)?.Value == originalProjectName; 590var originalDocumentPath = documentElement.Attribute(LinkFilePathAttributeName)?.Value; 599return d.Attribute(FilePathAttributeName)?.Value == originalDocumentPath; 624: (SourceCodeKind)Enum.Parse(typeof(SourceCodeKind), attr.Value); 699return filePathAttribute.Value; 716var folderContainers = folderAttribute.Value.Split(new[] { PathUtilities.DirectorySeparatorChar }, StringSplitOptions.RemoveEmptyEntries); 728var aliasElement = referencedSource.Attribute("Aliases")?.Value; 763assemblyName = assemblyNameAttribute.Value;
Workspaces\TestWorkspace`1.cs (1)
691var aliases = projectReference.Attributes(AliasAttributeName).Select(a => a.Value).ToImmutableArray();
Microsoft.CodeAnalysis.Workspaces.UnitTests (1)
UtilityTest\XmlDocumentationProviderTests.cs (1)
45Assert.Equal("T:Microsoft.CodeAnalysis.AdditionalTextFile", xmlDocument.Root!.Attribute("name")!.Value);
Microsoft.DotNet.Arcade.Sdk (11)
src\ExtractNgenMethodList.cs (2)
62if (int.TryParse(flagsInt?.Value.Substring(2), NumberStyles.HexNumber, CultureInfo.InvariantCulture, out int parsedFlagsInt) 65items.Add(name.Value);
src\GenerateResxSource.cs (1)
108string name = node.Attribute("name")?.Value;
src\SourceBuild\AddSourceMappingToNugetConfig.cs (1)
51.Select(e => e.Attribute("pattern").Value)
src\SourceBuild\AddSourceToNuGetConfig.cs (1)
50.FirstOrDefault(e => e.Attribute("key").Value == SourceName);
src\SourceBuild\ReadSourceBuildIntermediateNupkgDependencies.cs (6)
65string repoName = sourceBuildElement.Attribute("RepoName")?.Value; 73string dependencyName = d.Attribute("Name")?.Value ?? string.Empty; 81string dependencyVersion = d.Attribute("Version")?.Value; 85string sourceBuildRepoName = sourceBuildElement.Attribute("RepoName")?.Value; 86string sourceBuildManagedOnly = sourceBuildElement.Attribute("ManagedOnly")?.Value; 98sourceBuildElement.Attribute("ManagedOnly")?.Value,
Microsoft.DotNet.Arcade.Sdk.Tests (3)
SourceMappingToNugetConfigTest.cs (3)
56.Where(e => e.Attribute("key").Value == "foo") 65.Select(a => a.Value) 72.Select(a => a.Value)
Microsoft.DotNet.Build.Tasks.Installers (4)
src\GenerateMacOSDistributionFile.cs (2)
81.WithAttribute("id", c.Attribute("id").Value + ".alternate") 87.Select(c => new XElement("line", new XAttribute("choice", c.Attribute("id").Value)));
src\StabilizeWixFileId.cs (2)
72.Where(f => f.Attribute("Source")?.Value 95matchingFileElements[0].Attribute("Source").Value);
Microsoft.DotNet.Build.Tasks.Packaging (2)
PackageIndex.cs (2)
219string assemblyName = file.Attribute("AssemblyName").Value; 221Version supportedVersion = (versionAttribute != null) ? new Version(versionAttribute.Value) : VersionUtility.MaxVersion;
Microsoft.DotNet.Build.Tasks.VisualStudio (1)
Vsix\FinalizeInsertionVsixFile.cs (1)
87if (experimental == null || experimental.Value != "true")
Microsoft.DotNet.MacOsPkg (1)
Package.cs (1)
177pkgInfo.Attribute(elementName)?.Value ?? throw new Exception($"{elementName} is required in PackageInfo");
Microsoft.DotNet.NuGetRepack.Tasks (9)
src\NuGetVersionUpdater.cs (8)
145nuspecXmlns = xmlNsAttribute.Value; 273if (string.Equals(name?.Value, "DotnetTool", StringComparison.OrdinalIgnoreCase)) 297string id = dependency.Attribute("id")?.Value; 309if (!VersionRange.TryParse(versionRangeAttribute.Value, out var versionRange)) 311throw new InvalidDataException($"'{id}' has invalid version range: '{versionRangeAttribute.Value}'"); 319throw new InvalidDataException($"Unexpected dependency version range: '{id}, {versionRangeAttribute.Value}'"); 337if (allowPreReleaseDependencyOpt?.Invoke(package.Id, id, versionRangeAttribute.Value) != true) 339errors.Add(new InvalidOperationException($"Package '{package.Id}' depends on a pre-release package '{id}, {versionRangeAttribute.Value}'"));
src\ReplacePackageParts.cs (1)
151nuspecXmlns = xmlNsAttribute.Value;
Microsoft.DotNet.SignTool.Tests (1)
FakeBuildEngine.cs (1)
63FakeSignTool.SignFile(file.Attribute("Include").Value);
Microsoft.DotNet.SourceBuild.Tasks (10)
src\UsageReport\Usage.cs (4)
41AssetsFile = xml.Attribute("File")?.Value, 42IsDirectDependency = Convert.ToBoolean(xml.Attribute(nameof(IsDirectDependency))?.Value), 43IsAutoReferenced = Convert.ToBoolean(xml.Attribute(nameof(IsAutoReferenced))?.Value), 44RuntimePackageRid = xml.Attribute("Rid")?.Value
src\UsageReport\UsagePattern.cs (2)
22IdentityRegex = xml.Attribute(nameof(IdentityRegex))?.Value, 23IdentityGlob = xml.Attribute(nameof(IdentityGlob))?.Value
src\UsageReport\WriteUsageReports.cs (2)
86x.Attribute("Id")?.Value, 87x.Attribute("OriginBuildName")?.Value);
src\UsageReport\XmlParsingHelpers.cs (2)
27xml.Attribute("Id").Value, 28NuGetVersion.Parse(xml.Attribute("Version").Value));
Microsoft.DotNet.VersionTools (2)
BuildManifest\Model\XElementParsingExtensions.cs (2)
15string value = element.Attribute(name)?.Value; 26return element.Attributes().ToDictionary(a => a.Name.LocalName, a => a.Value);
Microsoft.DotNet.XliffTasks (16)
Model\ResxDocument.cs (2)
26string name = node.Attribute("name").Value; 61if (node.Attribute("type")?.Value == "System.Resources.ResXFileRef, System.Windows.Forms")
Model\VsctDocument.cs (4)
22string id = strings.Parent.Attribute("id").Value; 27string guid = strings.Parent.Attribute("guid").Value; 66string id = strings.Parent.Attribute("id").Value; 85string resourceRelativePath = hrefAttribute.Value.Replace('\\', Path.DirectorySeparatorChar);
Model\XamlRuleDocument.cs (5)
53var localizableProperties = element.Attribute(XName.Get(LocalizedPropertiesAttributeName, XliffTasksNs))?.Value?.Split(';'); 78source: attribute.Value, 88source: attribute.Value, 114source: attribute.Value, 220private static string? AttributedName(XElement element) => element.Attribute("Name")?.Value;
Model\XElementExtensions.cs (2)
54transUnitElement.Element(Target)?.Attribute("state")?.Value 136transUnitElement.Attribute("id").Value;
Model\XlfDocument.cs (1)
91if (originalAttribute.Value != sourceDocumentId)
Tasks\TransformTemplates.cs (2)
79string projectFileFullPath = Path.Combine(templateDirectory, projectNode.Attribute("File").Value); 80File.Copy(projectFileFullPath, Path.Combine(localizedTemplateDirectory, Path.GetFileName(projectNode.Attribute("File").Value)), overwrite: true);
Microsoft.DotNet.XliffTasks.Tests (3)
XElementExtensionsTests.cs (3)
126Assert.Equal(expected: "translated", actual: transUnitElement.Element(Target).Attribute("state").Value); 139Assert.Equal(expected: "translated", actual: transUnitElement.Element(Target).Attribute("state").Value); 151Assert.Equal(expected: "translated", actual: transUnitElement.Element(Target).Attribute("state").Value);
Microsoft.Extensions.FileProviders.Embedded (1)
Manifest\ManifestParser.cs (1)
128var value = element.Attribute("Name")?.Value;
Microsoft.Maui.Resizetizer (31)
GeneratePackageAppxManifest.cs (24)
93 if (attr == null || string.IsNullOrEmpty(attr.Value) || attr.Value == PackageNamePlaceholder) 104 if (attr == null || string.IsNullOrEmpty(attr.Value) || attr.Value == PackageVersionPlaceholder) 202 if (attr == null || string.IsNullOrEmpty(attr.Value) || attr.Value == DefaultPlaceholder) 210 if (attr == null || string.IsNullOrEmpty(attr.Value) || attr.Value == DefaultPlaceholder) 219 if (attr == null || string.IsNullOrEmpty(attr.Value)) 229 if (attr == null || string.IsNullOrEmpty(attr.Value) || attr.Value == PngPlaceholder) 241 if (attr == null || string.IsNullOrEmpty(attr.Value) || attr.Value == PngPlaceholder) 265 if (attr == null || string.IsNullOrEmpty(attr.Value) || attr.Value == PngPlaceholder) 277 if (attr == null || string.IsNullOrEmpty(attr.Value) || attr.Value == PngPlaceholder) 289 if (attr == null || string.IsNullOrEmpty(attr.Value) || attr.Value == PngPlaceholder) 303 if (attr == null || string.IsNullOrEmpty(attr.Value)) 319 if (showons.All(x => x.Attribute("Tile")?.Value != "square150x150Logo")) 321 if (showons.All(x => x.Attribute("Tile")?.Value != "wide310x150Logo")) 339 if (attr == null || string.IsNullOrEmpty(attr.Value) || attr.Value == PngPlaceholder)
GenerateTizenManifest.cs (7)
152 string dpiValue = icon.Attribute(DpiName).Value; 172 d => d.Attribute("type")?.Value == "img" 173 && d.Attribute(DpiName)?.Value == image.Key.Resolution 174 && d.Attribute("orientation")?.Value == image.Key.Orientation 175 && d.Attribute("indicator-display")?.Value == "false"); 193 if (attr == null || string.IsNullOrEmpty(attr.Value) || attr.Value == placeholder)
Microsoft.VisualStudio.LanguageServices (1)
Snippets\SnippetExpansionClient.cs (1)
317var delimiter = delimiterAttribute != null ? delimiterAttribute.Value : "$";
Roslyn.Test.PdbUtilities (6)
Reader\PdbValidation.cs (6)
377flags.SetValue(flags.Value.TrimEnd('0')); 489e.Name == "local" && e.Attributes().Any(a => a.Name.LocalName == "name" && a.Value.StartsWith("$VB$ResumableLocal_")) 496where e.Attributes().Any(a => a.Name.LocalName == "format" && a.Value == format) 659var expectedTags = pdbXml.DescendantsAndSelf("closure").Select((c, i) => new { Tag = $"<C:{i}>", StartIndex = methodStart + int.Parse(c.Attribute("offset").Value) }).ToList(); 662expectedTags.AddRange(pdbXml.DescendantsAndSelf("lambda").Select((c, i) => new { Tag = $"<L:{i}.{int.Parse(c.Attribute("closure").Value)}>", StartIndex = methodStart + int.Parse(c.Attribute("offset").Value) }));
System.ComponentModel.TypeConverter (1)
MS\Internal\Xml\Linq\ComponentModel\XComponentModel.cs (1)
475return _attribute.Value;
System.Private.Xml.Linq (23)
System\Xml\Linq\XAttribute.cs (1)
194/// representation and assigned to the <see cref="Value"/> property.
System\Xml\Linq\XElement.cs (2)
513if (a.Value == namespaceName) 1989if (a.IsNamespaceDeclaration && a.Name.LocalName == prefix) return a.Value;
System\Xml\Linq\XLinq.cs (6)
320_resolver.AddFirst(a.Name.NamespaceName.Length == 0 ? string.Empty : a.Name.LocalName, XNamespace.Get(a.Value)); 338_resolver.Add(a.Name.NamespaceName.Length == 0 ? string.Empty : a.Name.LocalName, XNamespace.Get(a.Value)); 384_writer.WriteAttributeString(GetPrefixOfNamespace(ns, false), localName, namespaceName.Length == 0 && localName == "xmlns" ? XNamespace.xmlnsPrefixNamespace : namespaceName, a.Value); 404await _writer.WriteAttributeStringAsync(GetPrefixOfNamespace(ns, false), localName, namespaceName.Length == 0 && localName == "xmlns" ? XNamespace.xmlnsPrefixNamespace : namespaceName, a.Value).ConfigureAwait(false); 553_writer.WriteAttributeString(GetPrefixOfNamespace(ns, false), localName, namespaceName.Length == 0 && localName == "xmlns" ? XNamespace.xmlnsPrefixNamespace : namespaceName, a.Value); 578_resolver.Add(a.Name.NamespaceName.Length == 0 ? string.Empty : a.Name.LocalName, XNamespace.Get(a.Value));
System\Xml\Linq\XNodeReader.cs (8)
370return ((XAttribute)o).Value; 405return a.Value; 431switch (a.Value.AsSpan().Trim(" \t\n\r")) 489return a.Value; 544return a.Value; 575return a.Value; 1355if (a.Value == candidateAttribute.Value)
System\Xml\Schema\XNodeValidator.cs (5)
190namespaceManager.AddNamespace(localName, a.Value); 215namespaceManager.AddNamespace(localName, a.Value); 222xsiType = a.Value; 226xsiNil = a.Value; 251validator!.ValidateAttribute(a.Name.LocalName, a.Name.NamespaceName, a.Value, si);
System\Xml\XPath\XNodeNavigator.cs (1)
277return ((XAttribute)_source).Value;