config

package
v1.0.4 Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2020 License: GPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetProviderSetting

func GetProviderSetting(providerCfg map[string]string, key string) (*string, error)

func Init

func Init(configFilePath string) error

func ShowUsing

func ShowUsing()

Types

type Configuration

type Configuration struct {
	Pvr      map[string]*Pvr
	Provider map[string]map[string]string
}
var (
	// Config exports the config object
	Config *Configuration
)

func (Configuration) ToJsonString

func (cfg Configuration) ToJsonString() (string, error)

type ExprEnv

type ExprEnv struct {
	MediaItem
	Now func() time.Time
}

func GetExprEnv

func GetExprEnv(media *MediaItem) *ExprEnv

Public

type MediaItem

type MediaItem struct {
	Provider  string
	Endpoint  string
	TvdbId    string
	TmdbId    string
	ImdbId    string
	Slug      string
	Title     string
	Summary   string
	Country   []string
	Network   string
	Date      time.Time
	Year      int
	Runtime   int
	Status    string
	Genres    []string
	Languages []string
	Character string
}

func (*MediaItem) String

func (m *MediaItem) String() string

type Pvr

type Pvr struct {
	Type           string
	URL            string
	ApiKey         string `mapstructure:"api_key"`
	QualityProfile string `mapstructure:"quality_profile"`
	RootFolder     string `mapstructure:"root_folder"`
	Filters        PvrFilters
}

type PvrFilters

type PvrFilters struct {
	Ignores []string
}

Jump to

Keyboard shortcuts

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