store

package
v0.5.4 Latest Latest
Warning

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

Go to latest
Published: Jan 20, 2019 License: AGPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Store

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

Store allows interaction with the discover.fm database

func New

func New(conf config.Config) (*Store, error)

New sets up a connection to the discover.fm database

func (*Store) AddSHOUTcastGenre

func (s *Store) AddSHOUTcastGenre(genre string) error

AddSHOUTcastGenre adds a roved SHOUTcast.com genre

func (*Store) AddSHOUTcastStation added in v0.3.0

func (s *Store) AddSHOUTcastStation(station shoutcastcom.Station) error

AddSHOUTcastStation adds a roved SHOUTcast.com station

func (*Store) AddTuneInGenre added in v0.5.0

func (s *Store) AddTuneInGenre(genre tunein.Genre) error

AddTuneInGenre adds a roved TuneIn genre

func (*Store) AddTuneInStation added in v0.5.0

func (s *Store) AddTuneInStation(station tunein.Station) error

AddTuneInStation adds a roved TuneIn station

func (*Store) Close added in v0.5.0

func (s *Store) Close()

Close closes the connection to the server

func (*Store) EnsureIndex added in v0.4.0

func (s *Store) EnsureIndex(ctx context.Context, c *mongo.Collection, keys []string, opts *options.IndexOptions) error

EnsureIndex will ensure the index model provided is on the given collection.

func (*Store) GetSHOUTcastGenres

func (s *Store) GetSHOUTcastGenres() ([]string, error)

GetSHOUTcastGenres gets the roved SHOUTcast.com genres

func (*Store) Migrate

func (s *Store) Migrate()

Migrate will make sure indexes are set

Jump to

Keyboard shortcuts

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