首页 | 主题 | 图库 | 问答 | 文摘 | 原创 | 百科

历史 | 地理 | 人物 | 艺术 | 体育 | 科学 | 音乐 | 电影 | 信息技术 | 世界遗产

 开放、中立,源自维基百科

Personal tools

Atom (standard)

From Wikipedia, the free encyclopedia

Jump to: navigation, search
Atom
The Firefox and Internet Explorer 7 Feed icon.
File extension: .atom, .xml
MIME type: application/atom+xml
Type of format: Syndication
Extended from: XML

The name Atom applies to a pair of related standards. The Atom Syndication Format is an XML language used for web feeds, while the Atom Publishing Protocol (short AtomPub or APP) is a simple HTTP-based protocol for creating and updating web resources.

Web feeds allow software programs to check for updates published on a web site. To provide a web feed, a site owner may use specialized software (such as a content management system) that publishes a list (or "feed") of recent articles or content in a standardized, machine-readable format. The feed can then be downloaded by web sites that syndicate content from the feed, or by feed reader programs that allow Internet users to subscribe to feeds and view their content.

A feed contains entries, which may be headlines, full-text articles, excerpts, summaries, and/or links to content on a web site, along with various metadata.

The Atom format was developed as an alternative to RSS. Ben Trott was one of the advocates of the new format that became Atom. He took note of the incompatibility between some of the versions of the RSS syndication format, and also believed that XML-RPC-based publishing protocols were not sufficiently interoperable.[1]

Proponents of the new format formed the IETF Atom Publishing Format and Protocol Workgroup. The Atom syndication format was published as an IETF "proposed standard" in RFC 4287, and the Atom Publishing Protocol was published as RFC 5023.

Contents

Usage

Web feeds are used by the weblog community to share the latest entries' headlines or their full text, and even attached multimedia files.[2] These providers allow other websites to incorporate the weblog's "syndicated" headline or headline-and-short-summary feeds under various usage agreements. Atom and other web syndication formats are now used for many purposes, including journalism, marketing, bug-reports, or any other activity involving periodic updates or publications. Atom also provides a standardized way to export an entire blog, or parts of it, for backup or for importing into other blogging systems.

A program known as a feed reader or aggregator can check webpages on behalf of a user and display any updated articles that it finds. It is common to find web feeds on major Web sites, as well as many smaller ones. Some websites let people choose between RSS or Atom formatted web feeds; others offer only RSS or only Atom. In particular, many blog and wiki sites offer their web feeds in the Atom format.

Client-side readers and aggregators may be designed as standalone programs or as extensions to existing programs like web browsers. Browsers are moving toward integrated feed reader functions. Such programs are available for various operating systems.

Web-based feed readers and news aggregators require no software installation and make the user's "feeds" available on any computer with Web access. Some aggregators syndicate (combine) web feeds into new feeds, e.g., taking all football related items from several sports feeds and providing a new football feed. There are several search engines which provide search functionality over content published via these web feeds.

On Web pages, web feeds (Atom or RSS) are typically linked with the word "Subscribe" or with the unofficial web feed logo ().

Atom compared to RSS 2.0

The main motivation for the development of Atom was dissatisfaction with RSS.[1] Among other things, there are multiple incompatible and widely adopted versions of RSS. The intention was to ease the difficulty of developing applications with web syndication feeds.

A brief description of some of the ways Atom 1.0 differs from RSS 2.0 follows:[3]

Content Model

RSS 2.0 may contain either plain text or escaped HTML as a payload, with no way to indicate which of two is provided. Atom, on the other hand, provides a mechanism to explicitly and unambiguously label the type of content being provided by the entry, and allows for a broad variety of payload types including plain text, escaped HTML, XHTML, XML, Base64-encoded binary, and references to external content such as documents, video, audio streams, and so forth.

Date Formats

The RSS 2.0 specification relies on the use of RFC 822 formatted timestamps to communicate information about when items in the feed were created and last updated. Alternatively, the Atom working group chose to use timestamps formatted according to the rules specified by RFC 3339 (which is a subset of ISO 8601).

Internationalization

While the RSS vocabulary has a mechanism to indicate a language for the feed, there is no means by which a language for individual items or text elements can be specified. Atom, on the other hand, uses the standardized xml:lang attribute to make it possible to specify a language context for every piece of human readable content in the feed.

Atom also differs from RSS in that it supports the use of Internationalized Resource Identifiers, which allow links to resources and unique identifiers to contain characters outside the US ASCII character set.

Modularity

The elements of the RSS vocabulary are not generally reusable in other XML vocabularies. The Atom syntax was specifically designed to allow elements to be reused outside the context of an Atom feed document. For instance, it is not uncommon to find atom:link elements being used within RSS 2.0 feed.

Barriers to adoption

Languages
AD Links