Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
Functions ¶
func NewTomlLoader ¶
func NewTomlLoader(source []byte) *tomlLoader
NewTomlLoader creates a new TOML configuration loader
Types ¶
type Loader ¶
type Loader interface { // LoadProto parses configuration and returns the Protocol Buffer config LoadProto() (*pbSettings.ServerConfig, error) // GetProtoConfig returns the underlying Protocol Buffer configuration GetProtoConfig() *pbSettings.ServerConfig }
Loader handles loading configuration from various sources
func NewLoaderFromBytes ¶
func NewLoaderFromBytes(data []byte, lodFunc LoaderFunc) (Loader, error)
NewLoaderFromBytes creates a new Loader with the provided bytes
func NewLoaderFromFilePath ¶
NewLoaderFromFilePath creates a new Loader from a file path
func NewLoaderFromReader ¶
func NewLoaderFromReader(reader io.Reader, lodFunc LoaderFunc) (Loader, error)
NewLoaderFromReader creates a new Loader from an io.Reader
type LoaderFunc ¶
Click to show internal directories.
Click to hide internal directories.