config

package
v0.0.0-...-863588f Latest Latest
Warning

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

Go to latest
Published: Mar 25, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Load

func Load(file string, in any) error

Types

type IConfig

type IConfig interface {
	SetConfig(cfg any)
	ReadFile(file string) error
	Decode() error
	Defaults() error
	Validate() error
}
var Config IConfig = &YAMLConfig{}

type YAMLConfig

type YAMLConfig struct {
	// contains filtered or unexported fields
}

func (*YAMLConfig) Decode

func (this *YAMLConfig) Decode() error

func (*YAMLConfig) Defaults

func (this *YAMLConfig) Defaults() error

func (*YAMLConfig) ReadFile

func (this *YAMLConfig) ReadFile(file string) error

func (*YAMLConfig) SetConfig

func (this *YAMLConfig) SetConfig(config any)

func (*YAMLConfig) Validate

func (this *YAMLConfig) Validate() error

Jump to

Keyboard shortcuts

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