external

package
v0.0.0-...-8dc1090 Latest Latest
Warning

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

Go to latest
Published: May 10, 2023 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Provider

type Provider struct {
	ExternalCalendarID   int
	ExternalCalendarName string
	ExternalCalendarURL  string
}

A Provider that implements the data.Provider interface for an external calendar.

func (*Provider) GetData

func (p *Provider) GetData(db *sql.DB, user *data.User, location *time.Location, startTime time.Time, endTime time.Time, dataType data.ProviderDataType) (data.ProviderData, error)

GetData gets the requested calendar data from the provider.

func (*Provider) ID

func (p *Provider) ID() string

ID returns the ID of the Provider.

func (*Provider) Name

func (p *Provider) Name() string

Name returns the name of the Provider.

func (*Provider) Update

func (p *Provider) Update(tx *sql.Tx) error

Update redownloads all events on the calendar from the source URL.

Jump to

Keyboard shortcuts

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