Documentation ¶
Index ¶
- Constants
- func HTML(content string) *atom_str
- func MarshalIndent(in Feed, indent string) (raw []byte, err error)
- func Standard(in Feed, allowedTimeFormats ...string) (out feeds.Feed, err error)
- func StandardCategories(in []Category) (out []feeds.Category)
- func StandardEntries(in []Entry, src feeds.FeedMeta, atfs ...string) (out []feeds.Entry, err error)
- func StandardEntry(in Entry, source feeds.FeedMeta, atfs ...string) (out feeds.Entry, err error)
- func StandardFeedMeta(in FeedMeta, atfs ...string) (out feeds.FeedMeta, err error)
- func StandardLink(in Link) (out feeds.Link)
- func StandardLinks(in []Link) (out []feeds.Link)
- func StandardPersons(in []Person) (out []feeds.Person)
- func StandardTime(in string, formats ...string) (out time.Time, errs error)
- func String(t, content string) *atom_str
- func Text(content string) *atom_str
- type Category
- type Entry
- type Feed
- type FeedMeta
- type Generator
- type Link
- type Person
Constants ¶
View Source
const ( TextTypeText = "text" TextTypeHtml = "html" )
Variables ¶
This section is empty.
Functions ¶
func HTML ¶
func HTML(content string) *atom_str
HTML returns an atom_str with type "html" if the content contains angle brackets.
func StandardEntries ¶
func StandardEntry ¶
func StandardFeedMeta ¶
Types ¶
type Category ¶
type Entry ¶
type Entry struct { common.XmlAttrs XMLName xml.Name `xml:"entry"` Title *atom_str `xml:"title"` Summary *atom_str `xml:"summary,omitempty"` Categories []Category `xml:"category,omitempty"` Links []Link `xml:"link"` Id string `xml:"id"` Updated string `xml:"updated"` Published string `xml:"published,omitempty"` Source *FeedMeta `xml:"source,omitempty"` Authors []Person `xml:"author,omitempty"` Contributors []Person `xml:"contributor,omitempty"` Extensions common.Extensions `xml:",any,omitempty"` Content *atom_str `xml:"content,omitempty"` }
type Feed ¶
type Feed struct { XMLName xml.Name `xml:"http://www.w3.org/2005/Atom feed"` FeedMeta Extensions common.Extensions `xml:",any,omitempty"` Entries []Entry `xml:"entry"` }
Feed is a single feed that can be marshalled to XML
type FeedMeta ¶
type FeedMeta struct { common.XmlAttrs Title *atom_str `xml:"title"` Subtitle *atom_str `xml:"subtitle,omitempty"` Icon string `xml:"icon,omitempty"` Logo string `xml:"logo,omitempty"` Categories []Category `xml:"category,omitempty"` Updated string `xml:"updated,omitempty"` Id string `xml:"id"` Links []Link `xml:"link"` Rights string `xml:"rights,omitempty"` Generator *Generator `xml:"generator,omitempty"` }
type Generator ¶
Click to show internal directories.
Click to hide internal directories.