feed-1.3.2.1: Interfacing with RSS (v 0.9x, 2.x, 1.0) + Atom feeds.

Copyright | (c) Galois Inc. 2008 (c) Sigbjorn Finne 2009-
License | BSD3
Maintainer | Sigbjorn Finne <sof@forkIO.com>
Stability | provisional
Portability | portable
Safe Haskell | Safe-Inferred
Language | Haskell2010

Text.Atom.Feed

Description

# Documentation

type URI = Text #

type NCName = Text #

type Date = Text #

type MediaType = Text #

type Attr = (Name, [Content]) #

data Feed #

Constructors

Feed |
Fields feedId :: URI feedTitle :: TextContent feedUpdated :: Date feedAuthors :: [Person] feedCategories :: [Category] feedContributors :: [Person] feedGenerator :: Maybe Generator feedIcon :: Maybe URI feedLinks :: [Link] feedLogo :: Maybe URI feedRights :: Maybe TextContent feedSubtitle :: Maybe TextContent feedEntries :: [Entry] feedAttrs :: [Attr] feedOther :: [Element]

#### Instances

Instances details

Show Feed # |
Instance details Defined in Text.Atom.Feed Methods showsPrec :: Int -> Feed -> ShowS # show :: Feed -> String # showList :: [Feed] -> ShowS #

data Entry #

Constructors

Entry |
Fields entryId :: URI entryTitle :: TextContent entryUpdated :: Date entryAuthors :: [Person] entryCategories :: [Category] entryContent :: Maybe EntryContent entryContributor :: [Person] entryLinks :: [Link] entryPublished :: Maybe Date entryRights :: Maybe TextContent entrySource :: Maybe Source entrySummary :: Maybe TextContent entryInReplyTo :: Maybe InReplyTo entryInReplyTotal :: Maybe InReplyTotal entryAttrs :: [Attr] entryOther :: [Element]

#### Instances

Instances details

Show Entry # |
Instance details Defined in Text.Atom.Feed Methods showsPrec :: Int -> Entry -> ShowS # show :: Entry -> String # showList :: [Entry] -> ShowS #

data EntryContent #

Constructors

TextContent Text |
HTMLContent Text |
XHTMLContent Element |
MixedContent (Maybe Text) [Node] |
ExternalContent (Maybe MediaType) URI |

#### Instances

Instances details

Show EntryContent # |
Instance details Defined in Text.Atom.Feed Methods showsPrec :: Int -> EntryContent -> ShowS # show :: EntryContent -> String # showList :: [EntryContent] -> ShowS #

data Category #

Constructors

Category |
Fields catTerm :: Text the tag/term of the category. catScheme :: Maybe URI optional URL for identifying the categorization scheme. catLabel :: Maybe Text human-readable label of the category catOther :: [Element] unknown elements, for extensibility.

#### Instances

Instances details

Show Category # |
Instance details Defined in Text.Atom.Feed Methods showsPrec :: Int -> Category -> ShowS # show :: Category -> String # showList :: [Category] -> ShowS #

data Generator #

Constructors

Generator |
Fields genURI :: Maybe URI genVersion :: Maybe Text genText :: Text

#### Instances

Instances details

Show Generator # |
Instance details Defined in Text.Atom.Feed Methods showsPrec :: Int -> Generator -> ShowS # show :: Generator -> String # showList :: [Generator] -> ShowS #
Eq Generator # |
Instance details Defined in Text.Atom.Feed Methods (==) :: Generator -> Generator -> Bool # (/=) :: Generator -> Generator -> Bool #

data Link #

Constructors

Link |
Fields linkHref :: URI linkRel :: Maybe (Either NCName URI) linkType :: Maybe MediaType linkHrefLang :: Maybe Text linkTitle :: Maybe Text linkLength :: Maybe Text linkAttrs :: [Attr] linkOther :: [Element]

#### Instances

Instances details

Show Link # |
Instance details Defined in Text.Atom.Feed Methods showsPrec :: Int -> Link -> ShowS # show :: Link -> String # showList :: [Link] -> ShowS #

data TextContent #

Constructors

TextString Text |
HTMLString Text |
XHTMLString Element |

#### Instances

Instances details

Show TextContent # |
Instance details Defined in Text.Atom.Feed Methods showsPrec :: Int -> TextContent -> ShowS # show :: TextContent -> String # showList :: [TextContent] -> ShowS #

txtToString :: TextContent -> String #

data Source #

Constructors

Source |
Fields sourceAuthors :: [Person] sourceCategories :: [Category] sourceGenerator :: Maybe Generator sourceIcon :: Maybe URI sourceId :: Maybe URI sourceLinks :: [Link] sourceLogo :: Maybe URI sourceRights :: Maybe TextContent sourceSubtitle :: Maybe TextContent sourceTitle :: Maybe TextContent sourceUpdated :: Maybe Date sourceOther :: [Element]

#### Instances

Instances details

Show Source # |
Instance details Defined in Text.Atom.Feed Methods showsPrec :: Int -> Source -> ShowS # show :: Source -> String # showList :: [Source] -> ShowS #

data Person #

Constructors

Person |
Fields personName :: Text personURI :: Maybe URI personEmail :: Maybe Text personOther :: [Element]

#### Instances

Instances details

Show Person # |
Instance details Defined in Text.Atom.Feed Methods showsPrec :: Int -> Person -> ShowS # show :: Person -> String # showList :: [Person] -> ShowS #

data InReplyTo #

Constructors

InReplyTo |
Fields replyToRef :: URI replyToHRef :: Maybe URI replyToType :: Maybe MediaType replyToSource :: Maybe URI replyToOther :: [Attr] replyToContent :: [Node]

#### Instances

Instances details

Show InReplyTo # |
Instance details Defined in Text.Atom.Feed Methods showsPrec :: Int -> InReplyTo -> ShowS # show :: InReplyTo -> String # showList :: [InReplyTo] -> ShowS #

data InReplyTotal #

Constructors

InReplyTotal |
Fields replyToTotal :: Integer replyToTotalOther :: [Attr]

#### Instances

Instances details

Show InReplyTotal # |
Instance details Defined in Text.Atom.Feed Methods showsPrec :: Int -> InReplyTotal -> ShowS # show :: InReplyTotal -> String # showList :: [InReplyTotal] -> ShowS #

newCategory #

Arguments

:: Text | catTerm
-> Category |

nullFeed #

Arguments

:: URI | feedId
-> TextContent | feedTitle
-> Date | feedUpdated
-> Feed |

nullEntry #

Arguments

:: URI | entryId
-> TextContent | entryTitle
-> Date | entryUpdated
-> Entry |

nullGenerator #

Arguments

:: Text | genText
-> Generator |

nullLink #

Arguments

:: URI | linkHref
-> Link |

nullSource :: Source #

nullPerson :: Person #