SyndicationGenerator Class

描述用于生成源的代理或工具。此类封装 RSS 2.0/rss/channel/generator 元素或 Atom 1.0/atom:feed/atom:generator 元素的信息。

语法


var syndicationGenerator = new Windows.Web.Syndication.SyndicationGenerator(string);
var syndicationGenerator = new Windows.Web.Syndication.SyndicationGenerator();

特性

[DualApiPartition()]
[MarshalingBehavior(Agile)]
[Threading(Both)]
[Version(0x06020000)]

成员

SyndicationGenerator类 具有这些类型的成员:

构造函数

SyndicationGenerator类 具有这些构造函数。

构造函数说明
SyndicationGenerator() Creates a new SyndicationGenerator object.
SyndicationGenerator(String) Creates a new SyndicationGenerator object with the specified Text property value.

 

方法

The SyndicationGenerator 类 具有这些方法。 对于 C#、Visual Basic 和 C++,它还继承方法于Object 类.

方法说明
GetXmlDocument Generates the DOM object that represents this element, all the attributes and child elements including foreign markups. The only formats accepted by this method are Atom 1.0 and RSS 2.0.

 

属性

SyndicationGenerator类 具有这些属性。

属性访问类型说明

AttributeExtensions

只读Gets the list of custom attributes of the element.

BaseUri

读/写Gets or sets the base URI for the element. This property represents the xml:base attribute on the element. It may be inherited from an ancestor element.

ElementExtensions

只读Gets the list of child elements within the element.

Language

读/写Gets or sets the language of the element. This property represents the xml:lang attribute on the element. It may be inherited from an ancestor element. It must be valid according to XML 1.0.

NodeName

读/写Gets or sets the local name of the element.

NodeNamespace

读/写Gets or sets the namespace of the element.

NodeValue

读/写Gets or sets the text content of the element. If the element contains only child elements, this property is NULL.

Text

读/写Gets or sets the text that identifies the generator.

Uri

读/写Gets or sets the Uniform Resource Identifier (URI) of the syndication generator.

Version

读/写Gets or sets the version of the generator.

 

备注

下表将 SyndicationGenerator 属性映射到 RSS and Atom 源元素。

SyndicationGeneratorRSSAtom
Text (节点值)(节点值)
Uri uri(特性)
Version version(特性)

 

要求

最低支持客户端

Windows 8 [Windows 应用商店应用程序, 桌面应用程序]

最低支持服务器

Windows Server 2012 [Windows 应用商店应用程序, 桌面应用程序]

命名空间

Windows.Web.Syndication
Windows::Web::Syndication [C++]

元数据

Windows.winmd

另请参见

快速入门:访问 web 源
联合示例

 

 

显示:
© 2015 Microsoft