Documentation ¶
Index ¶
Constants ¶
View Source
const (
YAML = DecoderType(iota)
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config interface { // if not found return default value Read(key, defaultValue string) string ReadInt(key string, defaultValue int) int ReadBool(key string, defaultValue bool) bool }
read config file
type DecoderType ¶
type DecoderType int
type FileSystemProvider ¶
type FileSystemProvider struct { }
func (*FileSystemProvider) Name ¶
func (p *FileSystemProvider) Name() string
type YAMLConfig ¶
type YAMLConfig struct {
// contains filtered or unexported fields
}
func NewYamlConfig ¶
func NewYamlConfig(fp string) (*YAMLConfig, error)
func (*YAMLConfig) Read ¶
func (r *YAMLConfig) Read(key, defaultValue string) string
type YAMLDecoder ¶
type YAMLDecoder struct{}
Click to show internal directories.
Click to hide internal directories.