storage

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Jan 10, 2021 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DefaultStorageFilename

func DefaultStorageFilename() string

DefaultStorageFilename returns the default location for storing channel URLs.

On UNIX and MacOS, it's $HOME/.streamerslive

On Windows, it's %USERPROFILE%/.streamerslive

Types

type ChannelURLsStorage

type ChannelURLsStorage struct {
	Filename string
}

ChannelURLsStorage is used to store ChannelURLs

func NewChannelURLsStorage

func NewChannelURLsStorage(filename string) *ChannelURLsStorage

NewChannelURLsStorage returns a new ChannelURLsStorage that uses filename to store ChannelURLs.

func (*ChannelURLsStorage) AddChannelURL

func (cus *ChannelURLsStorage) AddChannelURL(channelURL string) error

AddChannelURL add a channel URL to storage

func (*ChannelURLsStorage) ChannelURLs

func (cus *ChannelURLsStorage) ChannelURLs() ([]string, error)

ChannelURLs returns the stored channel URLs

func (*ChannelURLsStorage) RemoveChannelURL

func (cus *ChannelURLsStorage) RemoveChannelURL(channelURL string) error

RemoveChannelURL removes a channel URL from storage

Jump to

Keyboard shortcuts

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