Document furnace.syndication

db4
Slava Pestov 2008-11-14 23:01:04 -06:00
parent b9afd25245
commit c3c5b4f944
1 changed files with 12 additions and 8 deletions

View File

@ -1,4 +1,4 @@
USING: help.markup help.syntax io.streams.string kernel sequences strings urls syndication ; USING: help.markup help.syntax io.streams.string kernel sequences strings urls syndication calendar ;
IN: furnace.syndication IN: furnace.syndication
HELP: <feed-action> HELP: <feed-action>
@ -22,34 +22,38 @@ HELP: feed-action
HELP: feed-entry-date HELP: feed-entry-date
{ $values { $values
{ "object" object } { "object" object }
{ "timestamp" null } { "timestamp" timestamp }
} }
{ $description "" } ; { $contract "Outputs a feed entry timestmap." } ;
HELP: feed-entry-description HELP: feed-entry-description
{ $values { $values
{ "object" object } { "object" object }
{ "description" null } { "description" null }
} }
{ $description "" } ; { $contract "Outputs a feed entry description." } ;
HELP: feed-entry-title HELP: feed-entry-title
{ $values { $values
{ "object" object } { "object" object }
{ "string" string } { "string" string }
} }
{ $description "" } ; { $contract "Outputs a feed entry title." } ;
HELP: feed-entry-url HELP: feed-entry-url
{ $values { $values
{ "object" object } { "object" object }
{ "url" url } { "url" url }
} }
{ $description "" } ; { $contract "Outputs a feed entry URL." } ;
ARTICLE: "furnace.syndication.config" "Configuring Atom feed actions" ARTICLE: "furnace.syndication.config" "Configuring Atom feed actions"
"Instances of " { $link feed-action } " have three slots which need to be set:"
; { $table
{ { $slot "title" } "The title of the feed as a string" }
{ { $slot "url" } { "The feed " { $link url } } }
{ { $slot "entries" } { "A quotation with stack effect " { $snippet "( -- seq )" } ", which produces a sequence of objects responding to the " { $link "furnace.syndication.protocol" } " protocol" } }
} ;
ARTICLE: "furnace.syndication.protocol" "Atom feed entry protocol" ARTICLE: "furnace.syndication.protocol" "Atom feed entry protocol"
"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:" "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:"