config

package
v0.0.0-...-3e7ea43 Latest Latest
Warning

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

Go to latest
Published: Dec 22, 2024 License: MIT Imports: 3 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

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

func New

func New() *Config

func (*Config) Decode

func (cfg *Config) Decode(to any) error

func (*Config) DecodeWithConfig

func (cfg *Config) DecodeWithConfig(dc *mapstruct.DecoderConfig) error

func (*Config) Get

func (cfg *Config) Get() map[string]any

func (*Config) Load

func (cfg *Config) Load(l Loader) error

func (*Config) Merge

func (cfg *Config) Merge(msa map[string]any) error

func (*Config) ReadAndParse

func (cfg *Config) ReadAndParse(r Reader, p Parser) error

type Loader

type Loader interface {
	Load() (map[string]any, error)
}

type Parser

type Parser interface {
	Parse(bs []byte) (map[string]any, error)
}

type Reader

type Reader interface {
	Read() ([]byte, error)
}

Directories

Path Synopsis
parsers
readers

Jump to

Keyboard shortcuts

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