Documentation ¶
Index ¶
- Variables
- func GetArtifact(index Index, f FilterParams) (releaseversion.Artifact, error)
- type Factory
- type FilterParams
- func (f *FilterParams) ChecksumSatisfied(actual []metalink.Hash) bool
- func (f *FilterParams) LabelsSatisfied(actuals []string) bool
- func (f *FilterParams) NameSatisfied(actual string) bool
- func (f *FilterParams) URISatisfied(actualURL []metalink.URL, actualMetaURL []metalink.MetaURL) bool
- func (f *FilterParams) VersionSatisfied(actual string) bool
- type Index
- type NamedGetter
- type ProviderName
Constants ¶
This section is empty.
Variables ¶
View Source
var MultipleMatchErr = errors.New("multiple matches found")
View Source
var NoMatchErr = errors.New("no match found")
View Source
var UnsupportedOperationErr = errors.New("unsupported operation")
Functions ¶
func GetArtifact ¶
func GetArtifact(index Index, f FilterParams) (releaseversion.Artifact, error)
Types ¶
type Factory ¶
type Factory interface {
Create(provider ProviderName, name string, options map[string]interface{}) (Index, error)
}
type FilterParams ¶
type FilterParams struct { NameExpected bool Name string VersionExpected bool Version string VersionConstraint *semver.Constraints ChecksumExpected bool Checksum string URIExpected bool URI string LabelsExpected bool // TODO unnecessary? implied by len > 0 Labels []string }
func FilterParamsFromArtifact ¶
func FilterParamsFromArtifact(artifact releaseversion.Artifact) FilterParams
func FilterParamsFromMap ¶
func FilterParamsFromMap(args map[string]interface{}) (FilterParams, error)
func FilterParamsFromReference ¶
func FilterParamsFromReference(ref releaseversion.Reference) FilterParams
func FilterParamsFromSlug ¶
func FilterParamsFromSlug(slug string) FilterParams
func (*FilterParams) ChecksumSatisfied ¶
func (f *FilterParams) ChecksumSatisfied(actual []metalink.Hash) bool
func (*FilterParams) LabelsSatisfied ¶
func (f *FilterParams) LabelsSatisfied(actuals []string) bool
func (*FilterParams) NameSatisfied ¶
func (f *FilterParams) NameSatisfied(actual string) bool
func (*FilterParams) URISatisfied ¶
func (*FilterParams) VersionSatisfied ¶
func (f *FilterParams) VersionSatisfied(actual string) bool
type Index ¶
type Index interface { GetName() string GetArtifacts(f FilterParams) ([]releaseversion.Artifact, error) GetLabels() ([]string, error) FlushCache() error }
type NamedGetter ¶
type ProviderName ¶
type ProviderName string
Source Files ¶
Click to show internal directories.
Click to hide internal directories.