Documentation ¶
Index ¶
- Variables
- func GetBool(key string) bool
- func GetDuration(key string) time.Duration
- func GetEnvString(key string, defaultValue string) string
- func GetFloat64(key string) float64
- func GetInt(key string) int
- func GetInt32(key string) int32
- func GetInt64(key string) int64
- func GetIntSlice(key string) []int
- func GetSizeInBytes(key string) uint
- func GetString(key string) string
- func GetStringMap(key string) map[string]interface{}
- func GetStringMapString(key string) map[string]string
- func GetStringMapStringSlice(key string) map[string][]string
- func GetStringSlice(key string) []string
- func GetTime(key string) time.Time
- func GetUint(key string) uint
- func GetUint32(key string) uint32
- func GetUint64(key string) uint64
- func Load(path string) error
- func Set(key string, value interface{})
- func Watch()
- type Config
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // Get 查询配置/环境变量 Get func(string) string )
Functions ¶
func GetDuration ¶ added in v1.4.0
func GetEnvString ¶ added in v1.4.0
GetEnvString get value from env. application parameters take precedence over environment variables env := GetEnvString("APP_ENV", "")
func GetFloat64 ¶ added in v1.4.0
func GetIntSlice ¶ added in v1.5.0
func GetSizeInBytes ¶ added in v1.5.0
func GetStringMap ¶ added in v1.5.0
func GetStringMapString ¶ added in v1.5.0
func GetStringMapStringSlice ¶ added in v1.5.0
func GetStringSlice ¶ added in v1.5.0
Types ¶
Click to show internal directories.
Click to hide internal directories.