heads

package
v0.0.0-...-e95280a Latest Latest
Warning

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

Go to latest
Published: Jun 19, 2021 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Adapter

type Adapter interface {
	ToHead(parsed parsers.HeadCommand) (Head, error)
}

Adapter represents an adapter

func NewAdapter

func NewAdapter() Adapter

NewAdapter creates a new adapter instance

type Builder

type Builder interface {
	Create() Builder
	WithVariable(variable string) Builder
	WithValues(values []Value) Builder
	Now() (Head, error)
}

Builder represents an head builder

func NewBuilder

func NewBuilder() Builder

NewBuilder creates a new builder instance

type Head interface {
	Variable() string
	Values() []Value
}

Head represents a head command

type Value

type Value interface {
	IsName() bool
	Name() string
	IsVersion() bool
	Version() string
	IsImports() bool
	Imports() []parsers.ImportSingle
	IsLoads() bool
	Loads() []heads.LoadSingle
}

Value represents an head value

type ValueBuilder

type ValueBuilder interface {
	Create() ValueBuilder
	WithName(name string) ValueBuilder
	WithVersion(version string) ValueBuilder
	WithImports(imports []parsers.ImportSingle) ValueBuilder
	WithLoads(loads []heads.LoadSingle) ValueBuilder
	Now() (Value, error)
}

ValueBuilder represents an headValue builder

func NewValueBuilder

func NewValueBuilder() ValueBuilder

NewValueBuilder creates a new value builder instance

Jump to

Keyboard shortcuts

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