Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Value ¶
type Value interface { Bool(def ...bool) bool String(def ...string) string Float64(def ...float64) float64 Duration(def ...time.Duration) time.Duration StringSlice(def ...[]string) []string StringMap(def ...map[string]interface{}) map[string]interface{} StringMapString(def ...map[string]string) map[string]string Scan(val interface{}) error }
Value represent value of config fields
type Viper ¶
type Viper struct {
// contains filtered or unexported fields
}
func NewViper ¶
func NewViper(path string, opts ...ViperOptions) *Viper
func (*Viper) OnChange ¶
func (c *Viper) OnChange(callback OnChangedFunc)
type ViperOptions ¶
type ViperOptions interface {
Configure(v *Viper)
}
func ViperPaths ¶
func ViperPaths(paths ...string) ViperOptions
func ViperStandalone ¶
func ViperStandalone() ViperOptions
type ViperOptionsFunc ¶
type ViperOptionsFunc func(v *Viper)
func (ViperOptionsFunc) Configure ¶
func (f ViperOptionsFunc) Configure(v *Viper)
Click to show internal directories.
Click to hide internal directories.