config

package
v0.0.0-...-2d8c345 Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2019 License: BSD-2-Clause Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const CONFIG_FILENAME = ".config/plaincast.json"

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

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

func Get

func Get() *Config

Get returns a global Config instance. It may be called multiple times: the same object will be returned each time.

func (*Config) Get

func (c *Config) Get(key string, valueCall func() (interface{}, error)) (interface{}, error)

func (*Config) GetInt

func (c *Config) GetInt(key string, valueCall func() (int, error)) (int, error)

func (*Config) GetString

func (c *Config) GetString(key string, valueCall func() (string, error)) (string, error)

func (*Config) Set

func (c *Config) Set(key string, value interface{})

func (*Config) SetInt

func (c *Config) SetInt(key string, value int)

Jump to

Keyboard shortcuts

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