feed

package
v0.0.0-...-1fa1717 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 15, 2023 License: GPL-3.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var JST = time.FixedZone("Asia/Tokyo", 9*60*60)

Functions

func RunServer

func RunServer(ctx context.Context, cnf *config.Config)

Types

type Channel

type Channel struct {
	Title        string      `xml:"title"`
	Description  string      `xml:"description,omitempty"`
	Generator    string      `xml:"generator,omitempty"`
	Link         string      `xml:"link,omitempty"`
	NewFeedURL   string      `xml:"itunes:new-feed-url,omitempty"`
	ITunesAuthor string      `xml:"itunes:author,omitempty"`
	Explicit     string      `xml:"itunes:explicit,omitempty"`
	Keywords     string      `xml:"itunes:keywords,omitempty"`
	Subtitle     string      `xml:"itunes:subtitle,omitempty"`
	Summary      string      `xml:"itunes:summary,omitempty"`
	Owner        ITunesOwner `xml:"itunes:owner,omitempty"`
	Language     string      `xml:"language,omitempty"`
	Items        []Item      `xml:"item"`
}

type Contributor

type Contributor struct {
	Name string `xml:"http://www.w3.org/2005/Atom name"`
	URI  string `xml:"http://www.w3.org/2005/Atom uri"`
}

type Enclosure

type Enclosure struct {
	URL    string `xml:"url,attr"`
	Type   string `xml:"type,attr"`
	Length int64  `xml:"length,attr"`
}

type GUID

type GUID struct {
	IsPermaLink bool   `xml:"isPermaLink,attr"`
	Content     string `xml:",chardata"`
}

type ITunesOwner

type ITunesOwner struct {
	Name  string `xml:"itunes:name"`
	Email string `xml:"itunes:email,omitempty"`
}

type Item

type Item struct {
	Title       string    `xml:"title,omitempty"`
	Description string    `xml:"description,omitempty"`
	PubDate     string    `xml:"pubDate,omitempty"`
	Link        string    `xml:"link,omitempty"`
	GUID        GUID      `xml:"guid,omitempty"`
	Author      string    `xml:"itunes:author,omitempty"`
	Explicit    string    `xml:"itunes:explicit,omitempty"`
	Subtitle    string    `xml:"itunes:subtitle,omitempty"`
	Duration    string    `xml:"itunes:duration,omitempty"`
	Enclosure   Enclosure `xml:"enclosure"`

	PubDateTime time.Time `xml:"-"`
}

type RSS

type RSS struct {
	XMLName xml.Name `xml:"rss"`
	Version string   `xml:"version,attr"`
	Atom    string   `xml:"xmlns:atom,attr"`
	Itunes  string   `xml:"xmlns:itunes,attr"`
	Channel Channel  `xml:"channel"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL