SyndicationItem.Summary Egenskap

Definition

Hämtar eller anger sammanfattningen av syndikeringsobjektet.

public:
 property System::ServiceModel::Syndication::TextSyndicationContent ^ Summary { System::ServiceModel::Syndication::TextSyndicationContent ^ get(); void set(System::ServiceModel::Syndication::TextSyndicationContent ^ value); };
public System.ServiceModel.Syndication.TextSyndicationContent Summary { get; set; }
member this.Summary : System.ServiceModel.Syndication.TextSyndicationContent with get, set
Public Property Summary As TextSyndicationContent

Egenskapsvärde

En TextSyndicationContent som innehåller en sammanfattning av objektet.

Exempel

Följande kod visar hur du anger egenskapen på Summary en SyndicationItem instans.

SyndicationItem item = new SyndicationItem("Item Title", "Item Content", new Uri("http://Item/Alternate/Link"));
item.Summary = new TextSyndicationContent("This is a syndication item summary");
Dim item As New SyndicationItem("Item Title", "Item Content", New Uri("http:' Item/Alternate/Link"))
item.Summary = New TextSyndicationContent("This is a syndication item summary")

Följande XML visar hur egenskapen Summary serialiseras till Atom 1.0.

<summary type="text">this is a summary for my item</summary>

Följande XML visar hur egenskapen Summary serialiseras till RSS 2.0.

<description>this is a summary for my item</description>

Kommentarer

När den serialiseras till Atom 1.0 skrivs den här egenskapen till ett <summary> element. När den serialiseras till RSS 2.0 skrivs den här egenskapen till ett <description> element.

Gäller för