rssprovider

package
v0.0.0-...-b17c1e0 Latest Latest
Warning

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

Go to latest
Published: Sep 19, 2022 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RSSProvider

type RSSProvider struct {
	Label         string
	FeedURL       string
	PollFrequency time.Duration
}

RSSProvider provides functionality for retrieving RSS feeds

func NewRSSProvider

func NewRSSProvider(label, feedURL string, pollFrequency time.Duration) (*RSSProvider, error)

NewRSSProvider returns a new instance of RSSProvider

func (*RSSProvider) Latest

func (r *RSSProvider) Latest() ([]storage.Article, error)

Latest returns the latest items in the feed

func (*RSSProvider) PollingFrequency

func (r *RSSProvider) PollingFrequency() time.Duration

PollingFrequency returns the amount of time to wait between calls to `Latest()`

Jump to

Keyboard shortcuts

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