Documentation ¶
Index ¶
- type EmbedConfig
- func (e *EmbedConfig) Get(k string) interface{}
- func (e *EmbedConfig) GetBool(k string) bool
- func (e *EmbedConfig) GetConfig(k string) Getter
- func (e *EmbedConfig) GetFloat64(k string) float64
- func (e *EmbedConfig) GetInt(k string) int
- func (e *EmbedConfig) GetString(k string) string
- func (e *EmbedConfig) GetStringMap(k string) map[string]interface{}
- func (e *EmbedConfig) GetStringMapString(k string) map[string]string
- func (e *EmbedConfig) GetStringSlice(k string) []string
- func (e *EmbedConfig) Unmarshal(rawVal interface{}, opts ...viper.DecoderConfigOption) error
- type Getter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type EmbedConfig ¶
type EmbedConfig struct {
// contains filtered or unexported fields
}
EmbedConfig embeded config
func NewEmbedConfig ¶
func NewEmbedConfig(config interface{}) *EmbedConfig
NewEmbedConfig new embed config instance
func (*EmbedConfig) GetConfig ¶
func (e *EmbedConfig) GetConfig(k string) Getter
GetConfig get config
func (*EmbedConfig) GetFloat64 ¶
func (e *EmbedConfig) GetFloat64(k string) float64
GetFloat64 get float64 value
func (*EmbedConfig) GetString ¶
func (e *EmbedConfig) GetString(k string) string
GetString get string value
func (*EmbedConfig) GetStringMap ¶
func (e *EmbedConfig) GetStringMap(k string) map[string]interface{}
GetStringMap get map string interface value
func (*EmbedConfig) GetStringMapString ¶
func (e *EmbedConfig) GetStringMapString(k string) map[string]string
GetStringMapString get map string string value
func (*EmbedConfig) GetStringSlice ¶
func (e *EmbedConfig) GetStringSlice(k string) []string
GetStringSlice get string slice value
func (*EmbedConfig) Unmarshal ¶
func (e *EmbedConfig) Unmarshal(rawVal interface{}, opts ...viper.DecoderConfigOption) error
Unmarshal unmarshal
type Getter ¶
type Getter interface { Get(k string) interface{} GetString(k string) string GetBool(k string) bool GetInt(k string) int GetFloat64(k string) float64 GetStringSlice(k string) []string GetStringMap(k string) map[string]interface{} GetStringMapString(k string) map[string]string Unmarshal(rawVal interface{}, opts ...viper.DecoderConfigOption) error }
Getter config getter interface
Click to show internal directories.
Click to hide internal directories.