Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func QueryName

func QueryName(b string) string

Types

type Config

type Config struct {
	Log *log.Logger
}

type Frag

type Frag struct {
	Name  string
	Value string
}

type Item

type Item struct {
	Name    string
	Comment string `yaml:",omitempty"`

	Query    string
	Vars     string   `yaml:",omitempty"`
	Metadata Metadata `yaml:",inline,omitempty"`
	// contains filtered or unexported fields
}

type List

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

func New

func New(cpath string, conf Config) (*List, error)

func (*List) FragmentFetcher

func (al *List) FragmentFetcher() func(name string) (string, error)

func (*List) Load

func (al *List) Load() ([]Item, error)

func (*List) Set

func (al *List) Set(vars []byte, query string, md Metadata) error

type Metadata

type Metadata struct {
	Order struct {
		Var    string   `yaml:"var,omitempty"`
		Values []string `yaml:"values,omitempty"`
	} `yaml:",omitempty"`
}

Source Files