Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( Unmarshal = defaultConfig.Unmarshal Scan = defaultConfig.Scan Get = defaultConfig.Get GetString = defaultConfig.GetString GetBool = defaultConfig.GetBool GetInt = defaultConfig.GetInt GetFloat64 = defaultConfig.GetFloat64 GetDuration = defaultConfig.GetDuration GetIntSlice = defaultConfig.GetIntSlice GetStringSlice = defaultConfig.GetStringSlice GetStringMap = defaultConfig.GetStringMap OnChange = defaultConfig.OnChange )
Functions ¶
func ResetDefault ¶
func ResetDefault(c Config)
Types ¶
type Config ¶
type Config interface { Unmarshal(val any) error Scan(key string, val any) error Get(key string) any GetString(key string) string GetBool(key string) bool GetInt(key string) int GetFloat64(key string) float64 GetDuration(key string) time.Duration GetIntSlice(key string) []int GetStringSlice(key string) []string GetStringMap(key string) map[string]any OnChange(f OnChangeFunc) }
type OnChangeFunc ¶
type OnChangeFunc func(Config)
Click to show internal directories.
Click to hide internal directories.