共用方式為


SyndicationFeed.Copyright 屬性

定義

取得或設定摘要的著作權資訊。

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

屬性值

TextSyndicationContent

表示摘要之著作權資訊的 SyndicationContent 物件。

範例

下列程式碼會示範如何設定 SyndicationFeed 的著作權資訊。

SyndicationFeed feed = new SyndicationFeed("Feed Title", "Feed Description", new Uri("http://Feed/Alternate/Link"), "FeedID", DateTime.Now);
feed.Copyright = new TextSyndicationContent("Copyright 2007");
Dim feed As New SyndicationFeed("Feed Title", "Feed Description", New Uri("http:'Feed/Alternate/Link"), "FeedID", DateTime.Now)
feed.Copyright = New TextSyndicationContent("Copyright 2007")

下列 XML 會說明 Copyright 如何序列化為 Atom 1.0。

<rights type="text">Copyright 2007</rights>
<rights type="text">Copyright 2007</rights>  

下列 XML 說明 Copyright 將如何序列化為 RSS 2.0。

<copyright>Copyright 2007</copyright>

備註

當序列化為 Atom 1.0 時,會將 Copyright 寫入專案 <rights>

序列化為 RSS 2.0 時,會將 Copyright 寫入專案 <copyright>

適用於