SyndicationItem.GetAtom10Formatter Method

Definition

Gets an Atom10FeedFormatter instance.

C#
public System.ServiceModel.Syndication.Atom10ItemFormatter GetAtom10Formatter();

Returns

A Atom10FeedFormatter instance.

Examples

The following code shows how to write a syndication item in Atom 1.0 format to an XML file.

C#
SyndicationItem item = new SyndicationItem("Item Title", "Item Content", new Uri("http://Item/Alternate/Link"), "itemID", DateTimeOffset.Now);
Atom10ItemFormatter atomFormatter = item.GetAtom10Formatter();
XmlWriter writer = XmlWriter.Create("output.xml");
atomFormatter.WriteTo(writer);
writer.Close();

Applies to

Proizvod Verzije
.NET 8 (package-provided), 9 (package-provided), 10 (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, 4.7.1, 4.7.2, 4.8, 4.8.1
.NET Standard 2.0 (package-provided)