SyndicationFeed.Contributors プロパティ
定義
重要
一部の情報は、リリース前に大きく変更される可能性があるプレリリースされた製品に関するものです。 Microsoft は、ここに記載されている情報について、明示または黙示を問わず、一切保証しません。
フィードに対する共同作成者のコレクションを取得します。
public:
property System::Collections::ObjectModel::Collection<System::ServiceModel::Syndication::SyndicationPerson ^> ^ Contributors { System::Collections::ObjectModel::Collection<System::ServiceModel::Syndication::SyndicationPerson ^> ^ get(); };
public System.Collections.ObjectModel.Collection<System.ServiceModel.Syndication.SyndicationPerson> Contributors { get; }
member this.Contributors : System.Collections.ObjectModel.Collection<System.ServiceModel.Syndication.SyndicationPerson>
Public ReadOnly Property Contributors As Collection(Of SyndicationPerson)
プロパティ値
フィードの共同作成者を表す SyndicationPerson オブジェクトのコレクション。
例
次のコードは、SyndicationFeedのContributors コレクションに共同作成者を追加する方法を示しています。
SyndicationFeed feed = new SyndicationFeed("Feed Title", "Feed Description", new Uri("http://Feed/Alternate/Link"), "FeedID", DateTime.Now);
feed.Contributors.Add(new SyndicationPerson("jesper@contoso.com", "Jesper Aaberg", "http://contoso/jesper"));
Dim feed As New SyndicationFeed("Feed Title", "Feed Description", New Uri("http:'Feed/Alternate/Link"), "FeedID", DateTime.Now)
feed.Contributors.Add(New SyndicationPerson("jesper@contoso.com", "Jesper Aaberg", "http:'contoso/jesper"))
次の XML は、 Contributors コレクションを Atom 1.0 にシリアル化する方法を示しています。
<contributor>
<name>Lene Aalling</name>
<uri>http://contoso/Aalling</uri>
<email>Lene.Aaling@contoso.com</email>
</contributor>
次の XML は、 Contributors コレクションを RSS 2.0 にシリアル化する方法を示しています。
<a10:contributor>
<a10:name>Lene Aalling</a10:name>
<a10:uri>http://contoso/Aalling</a10:uri>
<a10:email>Lene.Aalling@contoso.com</a10:email>
</a10:contributor>
注釈
Atom 1.0 にシリアル化すると、コレクション内の各 SyndicationPerson が <contributor> 要素に書き込まれます。
RSS 2.0 にシリアル化すると、コレクション内の各 SyndicationPerson が <a10:contributor> 要素に書き込まれます。