Documentation
¶
Index ¶
- func Bool(key string, defaultValue bool) bool
- func Duration(key string, defaultValue time.Duration) time.Duration
- func Float32(key string, defaultValue float32) float32
- func Float64(key string, defaultValue float64) float64
- func Int(key string, defaultValue int) int
- func Int8(key string, defaultValue int8) int8
- func Int16(key string, defaultValue int16) int16
- func Int32(key string, defaultValue int32) int32
- func Int64(key string, defaultValue int64) int64
- func String(key string, defaultValue string) string
- func Uint(key string, defaultValue uint) uint
- func Uint8(key string, defaultValue uint8) uint8
- func Uint16(key string, defaultValue uint16) uint16
- func Uint32(key string, defaultValue uint32) uint32
- func Uint64(key string, defaultValue uint64) uint64
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Bool ¶
Bool returns a value from an environment variable defined by key. If key isn't set in the environment, returns defaultValue
func Duration ¶
Duration returns a value from an environment variable defined by key. If key isn't set in the environment, or doesn't parse as a time.Duration, returns defaultValue
func Float32 ¶ added in v0.0.6
Float32 returns a value from an environment variable defined by key. If key isn't set in the environment, or doesn't parse as a float32, returns defaultValue
func Float64 ¶
Float64 returns a value from an environment variable defined by key. If key isn't set in the environment, or doesn't parse as a float64, returns defaultValue
func Int ¶
Int returns a value from an environment variable defined by key. If key isn't set in the environment, or doesn't parse as an int, returns defaultValue
func Int8 ¶ added in v0.0.6
Int8 returns a value from an environment variable defined by key. If key isn't set in the environment, or doesn't parse as an int8, returns defaultValue
func Int16 ¶ added in v0.0.6
Int16 returns a value from an environment variable defined by key. If key isn't set in the environment, or doesn't parse as an int16, returns defaultValue
func Int32 ¶ added in v0.0.6
Int32 returns a value from an environment variable defined by key. If key isn't set in the environment, or doesn't parse as an int32, returns defaultValue
func Int64 ¶ added in v0.0.4
Int64 returns a value from an environment variable defined by key. If key isn't set in the environment, or doesn't parse as an int64, returns defaultValue
func String ¶
String returns a value from an environment variable defined by key. If key isn't set in the environment, returns defaultValue
func Uint ¶ added in v0.0.6
Uint returns a value from an environment variable defined by key. If key isn't set in the environment, or doesn't parse as an uint8, returns defaultValue
func Uint8 ¶ added in v0.0.5
Uint8 returns a value from an environment variable defined by key. If key isn't set in the environment, or doesn't parse as an uint8, returns defaultValue
func Uint16 ¶ added in v0.0.5
Uint16 returns a value from an environment variable defined by key. If key isn't set in the environment, or doesn't parse as an uint16, returns defaultValue
Types ¶
This section is empty.