brrss

package module
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jan 13, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func HTMLToFeed

func HTMLToFeed(body io.Reader, feedFormat FeedFormat, options HTMLToFeedOptions) (string, error)

func SelectText

func SelectText(item *goquery.Selection, selKind SelKind, selCustom string, options *SelectTextOptions) (string, error)

func TryParseTime

func TryParseTime(layout string, value string) time.Time

func TrySelectText

func TrySelectText(item *goquery.Selection, selKind SelKind, selCustom string, options *SelectTextOptions) string

Types

type FeedFormat

type FeedFormat string
const (
	AtomFeedFormat FeedFormat = "atom"
	JSONFeedFormat FeedFormat = "json"
	RSSFeedFormat  FeedFormat = "rss"
)

type HTMLToFeedOptions

type HTMLToFeedOptions struct {
	BaseURL      url.URL
	SelItem      string
	SelFeedTitle string
	SelFeedDesc  string
	SelItemTime  string
	SelItemDesc  string
	SelItemLink  string
	SelItemTitle string
}

type SelKind

type SelKind int64
const (
	FeedTitleSelKind SelKind = iota
	FeedDescSelKind
	ItemTitleSelKind
	ItemLinkSelKind
	ItemDescSelKind
	ItemTimeSelKind
)

type SelectTextOptions

type SelectTextOptions struct {
	BaseURL url.URL
}

Directories

Path Synopsis
cmd
Package docs Code generated by swaggo/swag.
Package docs Code generated by swaggo/swag.

Jump to

Keyboard shortcuts

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