28 references to Attributes
Microsoft.CodeAnalysis.CSharp (8)
Compiler\DocumentationCommentCompiler.cs (1)
513foreach (var attribute in elementSyntax.StartTag.Attributes)
Syntax.xml.Main.Generated.cs (1)
2149=> node.Update(VisitToken(node.LessThanToken), (XmlNameSyntax?)Visit(node.Name) ?? throw new ArgumentNullException("name"), VisitList(node.Attributes), VisitToken(node.GreaterThanToken));
Syntax.xml.Syntax.Generated.cs (6)
14840public XmlElementSyntax AddStartTagAttributes(params XmlAttributeSyntax[] items) => WithStartTag(this.StartTag.WithAttributes(this.StartTag.Attributes.AddRange(items))); 14889if (lessThanToken != this.LessThanToken || name != this.Name || attributes != this.Attributes || greaterThanToken != this.GreaterThanToken) 14899public XmlElementStartTagSyntax WithLessThanToken(SyntaxToken lessThanToken) => Update(lessThanToken, this.Name, this.Attributes, this.GreaterThanToken); 14900public XmlElementStartTagSyntax WithName(XmlNameSyntax name) => Update(this.LessThanToken, name, this.Attributes, this.GreaterThanToken); 14902public XmlElementStartTagSyntax WithGreaterThanToken(SyntaxToken greaterThanToken) => Update(this.LessThanToken, this.Name, this.Attributes, greaterThanToken); 14904public XmlElementStartTagSyntax AddAttributes(params XmlAttributeSyntax[] items) => WithAttributes(this.Attributes.AddRange(items));
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (2)
src\Analyzers\CSharp\CodeFixes\DocumentationComments\CSharpAddDocCommentNodesCodeFixProvider.cs (1)
35=> [.. node.StartTag.Attributes.OfType<XmlNameAttributeSyntax>()];
src\Analyzers\CSharp\CodeFixes\UsePrimaryConstructor\CSharpUsePrimaryConstructorCodeFixProvider_DocComments.cs (1)
203foreach (var attribute in paramElement.StartTag.Attributes)
Microsoft.CodeAnalysis.CSharp.Features (4)
ChangeSignature\CSharpChangeSignatureService.cs (1)
831var nameAttribute = paramNode.StartTag.Attributes.FirstOrDefault(a => a.Name.ToString().Equals("name", StringComparison.OrdinalIgnoreCase));
Completion\CompletionProviders\XmlDocCommentCompletionProvider.cs (1)
279attributes = startTagSyntax.Attributes;
src\Analyzers\CSharp\CodeFixes\DocumentationComments\CSharpAddDocCommentNodesCodeFixProvider.cs (1)
35=> [.. node.StartTag.Attributes.OfType<XmlNameAttributeSyntax>()];
src\Analyzers\CSharp\CodeFixes\UsePrimaryConstructor\CSharpUsePrimaryConstructorCodeFixProvider_DocComments.cs (1)
203foreach (var attribute in paramElement.StartTag.Attributes)
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (13)
Generated\Syntax.Test.xml.Generated.cs (2)
13840Assert.Equal(default, node.Attributes); 13842var newNode = node.WithLessThanToken(node.LessThanToken).WithName(node.Name).WithAttributes(node.Attributes).WithGreaterThanToken(node.GreaterThanToken);
LexicalAndXml\XmlDocCommentTests.cs (11)
1731VerifyXmlAttributes(xmlElement.StartTag.Attributes, new Dictionary<string, string>() { { "a", "as" } }); 1768VerifyXmlAttributes((firstComment.Content[1] as XmlElementSyntax).StartTag.Attributes, new Dictionary<string, string>() { { "a", "val" } }); 1771VerifyXmlAttributes((secondComment.Content[1] as XmlElementSyntax).StartTag.Attributes, new Dictionary<string, string>() { { "a", "as" } }); 1814VerifyXmlAttributes((secondComment.Content[1] as XmlElementSyntax).StartTag.Attributes, new Dictionary<string, string>() { { "a", "as" } }); 1884VerifyXmlAttributes((firstComment.Content[0] as XmlElementSyntax).StartTag.Attributes, new Dictionary<string, string>() { { "a", "val" } }); 1993Assert.Equal(0, (firstComment.Content[0] as XmlElementSyntax).StartTag.Attributes.Count); 2029Assert.Equal(0, (firstComment.Content[0] as XmlElementSyntax).StartTag.Attributes.Count); 2065VerifyXmlAttributes((firstComment.Content[0] as XmlElementSyntax).StartTag.Attributes, new Dictionary<string, string>() { { "a", "val" } }); 2131VerifyXmlAttributes((firstComment.Content[0] as XmlElementSyntax).StartTag.Attributes, new Dictionary<string, string>() { { "a", "val" } }); 2266VerifyXmlAttributes(((trivias[0].GetStructure() as DocumentationCommentTriviaSyntax).Content[0] as XmlElementSyntax).StartTag.Attributes, 2309VerifyXmlAttributes(thirdLevelTrivia.StartTag.Attributes, new Dictionary<string, string>() { { "attr", "a" } });
Microsoft.CodeAnalysis.CSharp.Workspaces (1)
Classification\Worker_DocumentationComments.cs (1)
219foreach (var attribute in node.Attributes)