configuration

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Oct 25, 2024 License: MIT Imports: 3 Imported by: 7

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GlobalViperConfig

type GlobalViperConfig struct {
}

func (*GlobalViperConfig) AddConfigPath

func (p *GlobalViperConfig) AddConfigPath(in string)

func (*GlobalViperConfig) AutomaticEnv

func (p *GlobalViperConfig) AutomaticEnv()

func (*GlobalViperConfig) BindFlagValue

func (p *GlobalViperConfig) BindFlagValue(key string, flag viper.FlagValue) error

func (*GlobalViperConfig) BindFlagValues

func (p *GlobalViperConfig) BindFlagValues(flags viper.FlagValueSet) error

func (*GlobalViperConfig) BindPFlag

func (p *GlobalViperConfig) BindPFlag(key string, flag *pflag.Flag) error

func (*GlobalViperConfig) ConfigFileUsed

func (p *GlobalViperConfig) ConfigFileUsed() string

func (*GlobalViperConfig) Get

func (p *GlobalViperConfig) Get(key string) interface{}

func (*GlobalViperConfig) GetBool

func (p *GlobalViperConfig) GetBool(key string) bool

func (*GlobalViperConfig) GetDuration

func (p *GlobalViperConfig) GetDuration(key string) time.Duration

func (*GlobalViperConfig) GetFloat64

func (p *GlobalViperConfig) GetFloat64(key string) float64

func (*GlobalViperConfig) GetInt

func (p *GlobalViperConfig) GetInt(key string) int

func (*GlobalViperConfig) GetInt32

func (p *GlobalViperConfig) GetInt32(key string) int32

func (*GlobalViperConfig) GetInt64

func (p *GlobalViperConfig) GetInt64(key string) int64

func (*GlobalViperConfig) GetIntSlice

func (p *GlobalViperConfig) GetIntSlice(key string) []int

func (*GlobalViperConfig) GetSizeInBytes

func (p *GlobalViperConfig) GetSizeInBytes(key string) uint

func (*GlobalViperConfig) GetString

func (p *GlobalViperConfig) GetString(key string) string

func (*GlobalViperConfig) GetStringMap

func (p *GlobalViperConfig) GetStringMap(key string) map[string]interface{}

func (*GlobalViperConfig) GetStringMapString

func (p *GlobalViperConfig) GetStringMapString(key string) map[string]string

func (*GlobalViperConfig) GetStringMapStringSlice

func (p *GlobalViperConfig) GetStringMapStringSlice(key string) map[string][]string

func (*GlobalViperConfig) GetStringSlice

func (p *GlobalViperConfig) GetStringSlice(key string) []string

func (*GlobalViperConfig) GetTime

func (p *GlobalViperConfig) GetTime(key string) time.Time

func (*GlobalViperConfig) GetUint

func (p *GlobalViperConfig) GetUint(key string) uint

func (*GlobalViperConfig) GetUint16

func (p *GlobalViperConfig) GetUint16(key string) uint16

func (*GlobalViperConfig) GetUint32

func (p *GlobalViperConfig) GetUint32(key string) uint32

func (*GlobalViperConfig) GetUint64

func (p *GlobalViperConfig) GetUint64(key string) uint64

func (*GlobalViperConfig) InConfig

func (p *GlobalViperConfig) InConfig(key string) bool

func (*GlobalViperConfig) ReadInConfig

func (p *GlobalViperConfig) ReadInConfig() error

func (*GlobalViperConfig) SetConfigFile

func (p *GlobalViperConfig) SetConfigFile(in string)

func (*GlobalViperConfig) SetConfigName

func (p *GlobalViperConfig) SetConfigName(in string)

func (*GlobalViperConfig) SetConfigType

func (p *GlobalViperConfig) SetConfigType(in string)

func (*GlobalViperConfig) SetTypeByDefaultValue

func (p *GlobalViperConfig) SetTypeByDefaultValue(enable bool)

func (*GlobalViperConfig) Sub

func (p *GlobalViperConfig) Sub(key string) *viper.Viper

func (*GlobalViperConfig) Unmarshal

func (p *GlobalViperConfig) Unmarshal(rawVal interface{}, opts ...viper.DecoderConfigOption) error

func (*GlobalViperConfig) UnmarshalExact

func (p *GlobalViperConfig) UnmarshalExact(rawVal interface{}, opts ...viper.DecoderConfigOption) error

func (*GlobalViperConfig) UnmarshalKey

func (p *GlobalViperConfig) UnmarshalKey(key string, rawVal interface{}, opts ...viper.DecoderConfigOption) error

type ViperConfig

type ViperConfig interface {
	AddConfigPath(in string)
	AutomaticEnv()
	BindFlagValue(key string, flag viper.FlagValue) error
	BindFlagValues(flags viper.FlagValueSet) error
	BindPFlag(key string, flag *pflag.Flag) error
	ConfigFileUsed() string
	Get(key string) interface{}
	GetBool(key string) bool
	GetDuration(key string) time.Duration
	GetFloat64(key string) float64
	GetInt(key string) int
	GetInt32(key string) int32
	GetInt64(key string) int64
	GetIntSlice(key string) []int
	GetUint(key string) uint
	GetUint16(key string) uint16
	GetUint32(key string) uint32
	GetUint64(key string) uint64
	GetTime(key string) time.Time
	GetSizeInBytes(key string) uint
	GetString(key string) string
	GetStringMap(key string) map[string]interface{}
	GetStringMapString(key string) map[string]string
	GetStringMapStringSlice(key string) map[string][]string
	GetStringSlice(key string) []string
	InConfig(key string) bool
	ReadInConfig() error
	SetConfigFile(in string)
	SetConfigName(in string)
	SetConfigType(in string)
	SetTypeByDefaultValue(enable bool)
	Sub(key string) *viper.Viper
	Unmarshal(rawVal interface{}, opts ...viper.DecoderConfigOption) error
	UnmarshalExact(rawVal interface{}, opts ...viper.DecoderConfigOption) error
	UnmarshalKey(key string, rawVal interface{}, opts ...viper.DecoderConfigOption) error
}

Jump to

Keyboard shortcuts

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