Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrInvalidSourceEmpty = fmt.Errorf("invalid source, must specify at least one type of source configuration")
Functions ¶
This section is empty.
Types ¶
type Entry ¶
Entry is a single sourced entry. It's just a basic map, but makes it much clearer when building lists of this type, as the type syntax can get a bit messy.
type Source ¶
type Source struct { Local *SourceLocal `json:"local,omitempty"` Inline *SourceInline `json:"inline,omitempty" doc:"Define entries on this source to load them directly."` }
Source is instantiated from configuration and represents a source of catalog files.
type SourceEntry ¶
SourceEntry is an entry that has been discovered in a source, with the contents of the source file and an Origin that explains where the entry came from, specific to the type of source that produced it.
func (SourceEntry) Parse ¶
func (e SourceEntry) Parse() ([]Entry, error)
type SourceInline ¶
func (SourceInline) Load ¶
func (s SourceInline) Load(ctx context.Context) ([]*SourceEntry, error)
type SourceLocal ¶
type SourceLocal struct {
Files []string `json:"files"`
}
func (SourceLocal) Load ¶
func (s SourceLocal) Load(ctx context.Context) ([]*SourceEntry, error)
Click to show internal directories.
Click to hide internal directories.