Documentation ¶
Overview ¶
Package toml is driver use TOML format content as config source
Usage please see example:
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Decoder config.Decoder = func(blob []byte, ptr interface{}) (err error) { _, err = toml.Decode(string(blob), ptr) return }
Decoder the toml content decoder
View Source
var Driver = &tomlDriver{config.Toml}
Driver for toml
View Source
var Encoder config.Encoder = func(ptr interface{}) (out []byte, err error) { buf := new(bytes.Buffer) err = toml.NewEncoder(buf).Encode(ptr) if err != nil { return } return buf.Bytes(), nil }
Encoder the toml content encoder
Functions ¶
This section is empty.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.