loader

package
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: Jul 9, 2021 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type File

type File struct {
	Name      string
	Content   string
	Extension string
}

type JSONLoader

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

func NewJSONLoader

func NewJSONLoader(basePath string) *JSONLoader

func (*JSONLoader) Load

func (jl *JSONLoader) Load(configurationName string) (configuration.Index, error)

func (*JSONLoader) LoadAll

func (jl *JSONLoader) LoadAll() (configuration.IndexCollection, error)

func (*JSONLoader) Supports

func (jl *JSONLoader) Supports() []string

type Loader

type Loader interface {
	LoadAll() (configuration.IndexCollection, error)
	Load(configurationName string) (configuration.Index, error)
	Supports() []string
}

type Registry

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

func NewRegistry

func NewRegistry(path string) *Registry

func (*Registry) GetByFormat

func (r *Registry) GetByFormat(format string) (Loader, error)

type YAMLLoader

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

func NewYAMLLoader

func NewYAMLLoader(basePath string) *YAMLLoader

func (*YAMLLoader) Load

func (yl *YAMLLoader) Load(configurationName string) (configuration.Index, error)

func (*YAMLLoader) LoadAll

func (yl *YAMLLoader) LoadAll() (configuration.IndexCollection, error)

func (*YAMLLoader) Supports

func (yl *YAMLLoader) Supports() []string

Jump to

Keyboard shortcuts

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