Description

Really Simple Syndication (RSS) is a family of formats that describe
‘feeds,’ specially constructed XML documents that
allow an interested person to subscribe and receive updates from a
particular web service. This portion of the standard library provides
tooling to read and create these feeds.

The standard library supports RSS 0.91, 1.0, 2.0,
and Atom, a related format. Here are some links to the standards documents
for these formats:

As you can see, the workhorse is RSS::Parser#parse, which takes the source
of the feed and a parameter that performs validation on the feed. We get
back an object that has all of the data from our feed, accessible through
methods. This example shows getting the title out of the channel element,
and looping through the list of items.

As you can see, this is a very Builder-like DSL. This code will spit out an
Atom feed with one item. If we needed a second item, we’d make another
block with maker.items.new_item and build a second one.