mirror of https://github.com/spf13/viper.git
add method for GetStringMapBool
This commit is contained in:
parent
0967fc9ace
commit
b4f55a56ad
6
viper.go
6
viper.go
|
@ -703,6 +703,12 @@ func (v *Viper) GetStringMapString(key string) map[string]string {
|
||||||
return cast.ToStringMapString(v.Get(key))
|
return cast.ToStringMapString(v.Get(key))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// GetStringMapBool returns the value associated with the key as a map of strings.
|
||||||
|
func GetStringMapBool(key string) map[string]bool { return v.GetStringMapBool(key) }
|
||||||
|
func (v *Viper) GetStringMapBool(key string) map[string]bool {
|
||||||
|
return cast.ToStringMapBool(v.Get(key))
|
||||||
|
}
|
||||||
|
|
||||||
// GetStringMapStringSlice returns the value associated with the key as a map to a slice of strings.
|
// GetStringMapStringSlice returns the value associated with the key as a map to a slice of strings.
|
||||||
func GetStringMapStringSlice(key string) map[string][]string { return v.GetStringMapStringSlice(key) }
|
func GetStringMapStringSlice(key string) map[string][]string { return v.GetStringMapStringSlice(key) }
|
||||||
func (v *Viper) GetStringMapStringSlice(key string) map[string][]string {
|
func (v *Viper) GetStringMapStringSlice(key string) map[string][]string {
|
||||||
|
|
Loading…
Reference in New Issue