feed

package
v0.8.1 Latest Latest
Warning

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

Go to latest
Published: Apr 5, 2024 License: GPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultTimeout = 30 * time.Second
)

Variables

View Source
var (
	DefaultOptions = Options{
		Timeout:   DefaultTimeout,
		UserAgent: fetch.DefaultUserAgent,
	}
)

Functions

This section is empty.

Types

type FeedFetcher

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

func NewFeedFetcher

func NewFeedFetcher(options Options) *FeedFetcher

func (*FeedFetcher) Close

func (f *FeedFetcher) Close() error

func (*FeedFetcher) Fetch

func (f *FeedFetcher) Fetch(url *nurl.URL) (*resource.Feed, error)

func (*FeedFetcher) Open

func (f *FeedFetcher) Open(ctx context.Context) error

type Options

type Options struct {
	UserAgent string
	Timeout   time.Duration
	Client    *http.Client
}

Jump to

Keyboard shortcuts

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