Documentation ¶
Index ¶
- Constants
- Variables
- func AddConfigPath(path string)
- func AutomaticEnv()
- func GetBool(key string) bool
- func GetDuration(key string) time.Duration
- func GetFloat64(key string) float64
- func GetInt(key string) int
- func GetIntSlice(key string) []int
- func GetString(key string) string
- func GetStringMapString(key string) map[string]string
- func GetStringSlice(key string) []string
- func GetUint(key string) uint
- func GetUint64(key string) uint64
- func IsSet(key string) bool
- func ReadInConfig() error
- func Set(key string, value interface{})
- func SetConfigName(name string)
- func WatchConfig()
Constants ¶
View Source
const (
TimeStampFormat = "2006-01-02 15:04:05"
)
Variables ¶
View Source
var DefaultInstance = &config{viper.New()}
Functions ¶
func AddConfigPath ¶
func AddConfigPath(path string)
func AutomaticEnv ¶
func AutomaticEnv()
func GetDuration ¶
func GetFloat64 ¶
func GetIntSlice ¶
func GetStringMapString ¶
func GetStringSlice ¶
func ReadInConfig ¶
func ReadInConfig() error
func SetConfigName ¶
func SetConfigName(name string)
func WatchConfig ¶
func WatchConfig()
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.