1 USING: help.markup help.syntax io.streams.string kernel sequences strings urls syndication calendar ;
2 IN: furnace.syndication
5 { $values { "action" feed-action } }
6 { $description "Creates a new Atom feed action." } ;
13 { $contract "Converts an object into an Atom feed entry. The default implementation constructs an entry by calling "
14 { $link feed-entry-title } ", "
15 { $link feed-entry-description } ", "
16 { $link feed-entry-date } ", and "
17 { $link feed-entry-url } "." } ;
20 { $class-description "The class of feed actions. Contains several slots, documented in " { $link "furnace.syndication.config" } "." } ;
25 { "timestamp" timestamp }
27 { $contract "Outputs a feed entry timestmap." } ;
29 HELP: feed-entry-description
32 { "description" null }
34 { $contract "Outputs a feed entry description." } ;
36 HELP: feed-entry-title
41 { $contract "Outputs a feed entry title." } ;
48 { $contract "Outputs a feed entry URL." } ;
50 ARTICLE: "furnace.syndication.config" "Configuring Atom feed actions"
51 "Instances of " { $link feed-action } " have three slots which need to be set:"
53 { { $slot "title" } "The title of the feed as a string" }
54 { { $slot "url" } { "The feed " { $link url } } }
55 { { $slot "entries" } { "A quotation with stack effect " { $snippet "( -- seq )" } ", which produces a sequence of objects responding to the " { $link "furnace.syndication.protocol" } " protocol" } }
58 ARTICLE: "furnace.syndication.protocol" "Atom feed entry protocol"
59 "An Atom feed action takes a sequence of objects and converts them into Atom feed entries. The objects must implement a protocol consisting of either a single generic word:"
60 { $subsection >entry }
61 "Or a series of generic words, called by the default implementation of " { $link >entry } ":"
62 { $subsection feed-entry-title }
63 { $subsection feed-entry-description }
64 { $subsection feed-entry-date }
65 { $subsection feed-entry-url } ;
67 ARTICLE: "furnace.syndication" "Furnace Atom syndication support"
68 "The " { $vocab-link "furnace.syndication" } " vocabulary builds on the " { $link "syndication" } " library by providing easy support for generating Atom feeds from " { $link "furnace.actions" } "."
69 { $subsection <feed-action> }
70 { $subsection "furnace.syndication.config" }
71 { $subsection "furnace.syndication.protocol" } ;
73 ABOUT: "furnace.syndication"