config

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 10, 2021 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetBool

func GetBool(key string, fallback bool) bool

GetBool use for get bool-type value

func GetDuration

func GetDuration(key string, fallback time.Duration) time.Duration

GetDuration exporter

func GetFloat64

func GetFloat64(key string, fallback float64) float64

GetFloat64 exporter

func GetInt

func GetInt(key string, fallback int) int

GetInt use for get int-type value

func GetIntSlice

func GetIntSlice(key string, fallback []int) []int

GetIntSlice exporter

func GetString

func GetString(key string, fallback string) string

GetString use for get string-type value

func GetStringMap

func GetStringMap(key string, fallback map[string]interface{}) map[string]interface{}

GetStringMap exporter

func GetStringMapString

func GetStringMapString(key string, fallback map[string]string) map[string]string

GetStringMapString exporter

func GetStringMapStringSlice

func GetStringMapStringSlice(key string, fallback map[string][]string) map[string][]string

GetStringMapStringSlice exporter

func GetStringSlice

func GetStringSlice(key string, fallback []string) []string

GetStringSlice exporter

func GetTime

func GetTime(key string, fallback time.Time) time.Time

GetTime exporter

func Init

func Init(addr, path string) (err error)

Init for init config

func Instance

func Instance() *config.Config

Instance return the instance of Config

func IsSet

func IsSet(key string) bool

IsSet use for detected key isset

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL