ruanyifeng

package
v0.0.0-...-636a148 Latest Latest
Warning

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

Go to latest
Published: Jul 4, 2020 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	RSSURL = "http://www.ruanyifeng.com/blog/atom.xml"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Author

type Author struct {
	XMLName xml.Name `xml:"author"`
	Name    string   `xml:"name"`
	Uri     string   `xml:"uri"`
}

type Category

type Category struct {
	XMLName xml.Name `xml:"category"`
	Term    string   `xml:"term,attr"`
	Scheme  string   `xml:"scheme,attr"`
}

type Content

type Content struct {
	XMLName xml.Name `xml:"content"`
	Type    string   `xml:"type,attr"`
	Lang    string   `xml:"lang,attr"`
	Base    string   `xml:"base,attr"`

	Data []byte `xml:",cdata"`
}

type Entry

type Entry struct {
	XMLName xml.Name `xml:"entry"`
	Title   string   `xml:"title"`

	Link      *Link  `xml:"link"`
	ID        string `xml:"id"`
	Published string `xml:"published"`
	Updated   string `xml:"updated"`
	Summary   string `xml:"summary"`

	Author   *Author   `xml:"author"`
	Category *Category `xml:"category"`
	Content  *Content  `xml:"content"`
}

type Feed

type Feed struct {
	XMLName xml.Name `xml:"feed"`
	Xmlns   string   `xml:"xmlns,attr"`
	Title   string   `xml:"title"`

	Links     []*Link    `xml:"link"`
	ID        string     `xml:"id"`
	Updated   string     `xml:"updated"`
	Subtitle  string     `xml:"subtitle"`
	Generator *Generator `xml:"generator"`

	Entries []*Entry `xml:"entry"`
}

type Generator

type Generator struct {
	XMLName xml.Name `xml:"generator"`
	Uri     string   `xml:"uri,attr"`
	Data    string   `xml:",innerxml"`
}
type Link struct {
	XMLName xml.Name `xml:"link"`
	Rel     string   `xml:"rel,attr"`
	Type    string   `xml:"type,attr"`
	Href    string   `xml:"href,attr"`
}

type RuanYiFeng

type RuanYiFeng struct {
	// contains filtered or unexported fields
}

func NewRuanYiFeng

func NewRuanYiFeng() *RuanYiFeng

func (*RuanYiFeng) SendUpdate

func (ryf *RuanYiFeng) SendUpdate()

func (*RuanYiFeng) UpdateEntry

func (ryf *RuanYiFeng) UpdateEntry()

Jump to

Keyboard shortcuts

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