go-pkg-rss/channel.go

41 lines
750 B
Go
Raw Normal View History

package feeder
type Channel struct {
Title string
Links []Link
Description string
Language string
Copyright string
ManagingEditor string
WebMaster string
PubDate string
LastBuildDate string
Docs string
Categories []*Category
Generator Generator
TTL int
Rating string
SkipHours []int
SkipDays []int
Image Image
Items []*Item
Cloud Cloud
TextInput Input
2014-01-23 19:37:50 +00:00
Extensions map[string]map[string][]Extension
// Atom fields
Id string
Rights string
Author Author
SubTitle SubTitle
}
2013-12-05 15:04:00 +00:00
func (c *Channel) Key() string {
switch {
case len(c.Id) != 0:
return c.Id
default:
return c.Title
}
}