rhctag

package
v1.4.1 Latest Latest
Warning

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

Go to latest
Published: Jun 6, 2022 License: Apache-2.0 Imports: 6 Imported by: 1

Documentation

Overview

Package rhctag implements types for working with versions as used in the Red Hat Container Catalog.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Version

type Version struct {
	Original string
	Major    int
	Minor    int
}

This class also handles container tags which have a 'v' prefix, for example openshift4/ose-metering-hive 4.6 minor: v4.6.0-202112140546.p0.g8b9da97.assembly.stream 4.7 minor: v4.7.0-202112140553.p0.g091bb99.assembly.stream

func Parse

func Parse(s string) (v Version, err error)

Parse attempts to extract a Red Hat container registry tag version string from the provided string.

func (*Version) Compare

func (v *Version) Compare(x *Version) int

func (*Version) MinorStart

func (v *Version) MinorStart() (start Version)

MinorStart returns a Version which is lower than all others in the minor range major-minor series of the receiver.

func (*Version) Version

func (v *Version) Version(min bool) (c claircore.Version)

type Versions

type Versions []Version

Versions implements sort.Interface.

func (Versions) Append

func (vs Versions) Append(v Version) Versions

func (Versions) First

func (vs Versions) First() (Version, error)

func (Versions) Len

func (vs Versions) Len() int

func (Versions) Less

func (vs Versions) Less(i, j int) bool

func (Versions) Swap

func (vs Versions) Swap(i, j int)

Jump to

Keyboard shortcuts

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