config

package
v0.0.0-...-5157df0 Latest Latest
Warning

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

Go to latest
Published: Jun 3, 2018 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CONFIG_TP_INI  = "ini"
	CONFIG_TP_JSON = "json"
	CONFIG_TP_YAML = "yaml"
)

Variables

This section is empty.

Functions

func LoadConfig

func LoadConfig(cfgtp, filename string, out interface{}) error

func Register

func Register(cfgtp string, mgr CfgManager)

Types

type CfgManager

type CfgManager interface {
	Parse(data []byte, out interface{}) error
}

type ConfigIni

type ConfigIni struct {
}

func (ConfigIni) Parse

func (ci ConfigIni) Parse(data []byte, out interface{}) error

type ConfigJson

type ConfigJson struct {
}

func (ConfigJson) Parse

func (cj ConfigJson) Parse(data []byte, out interface{}) error

type ConfigYaml

type ConfigYaml struct {
}

func (ConfigYaml) Parse

func (cy ConfigYaml) Parse(data []byte, out interface{}) error

Jump to

Keyboard shortcuts

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