SyndicationLink.AttributeExtensions Property

Definition

Gets the attribute extensions of the link.

public System.Collections.Generic.Dictionary<System.Xml.XmlQualifiedName,string> AttributeExtensions { get; }

Property Value

A dictionary that contains a collection of attribute extensions.

Examples

The following code shows how to add an attribute extension to a syndication link.

SyndicationLink link = new SyndicationLink(new Uri("http://server/link"));
link.AttributeExtensions.Add(new XmlQualifiedName("myAttribute", ""), "someValue");

Remarks

AttributeExtensions allows you to add custom attributes to the SyndicationLink. When serialized to Atom 1.0, the custom attributes appear within the <link> element. When serialized to RSS 2.0, the custom attributes appear in the <a10:link> element. Any valid XML attribute can be added.

Applies to

Produit Versions
.NET 8 (package-provided), 9 (package-provided)
.NET Framework 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7 (package-provided), 4.7, 4.7.1 (package-provided), 4.7.1, 4.7.2 (package-provided), 4.7.2, 4.8 (package-provided), 4.8, 4.8.1
.NET Standard 2.0 (package-provided)