property

package
v1.17.5 Latest Latest
Warning

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

Go to latest
Published: Jul 14, 2021 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TypePackage         = "olm.package"
	TypePackageRequired = "olm.package.required"
	TypeChannel         = "olm.channel"
	TypeGVK             = "olm.gvk"
	TypeGVKRequired     = "olm.gvk.required"
	TypeSkips           = "olm.skips"
	TypeSkipRange       = "olm.skipRange"
	TypeBundleObject    = "olm.bundle.object"
)

Variables

This section is empty.

Functions

func AddToScheme

func AddToScheme(typ string, p interface{})

Types

type BundleObject

type BundleObject struct {
	File `json:",inline"`
}

type Channel

type Channel struct {
	Name     string `json:"name"`
	Replaces string `json:"replaces,omitempty"`
}

type File

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

func (File) GetData

func (f File) GetData(root fs.FS, cwd string) ([]byte, error)

func (File) GetRef

func (f File) GetRef() string

func (File) IsRef

func (f File) IsRef() bool

func (File) MarshalJSON

func (f File) MarshalJSON() ([]byte, error)

func (*File) UnmarshalJSON

func (f *File) UnmarshalJSON(data []byte) error

type GVK

type GVK struct {
	Group   string `json:"group"`
	Kind    string `json:"kind"`
	Version string `json:"version"`
}

type GVKRequired

type GVKRequired struct {
	Group   string `json:"group"`
	Kind    string `json:"kind"`
	Version string `json:"version"`
}

type MatchMissingError

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

func (MatchMissingError) Error

func (e MatchMissingError) Error() string

type Package

type Package struct {
	PackageName string `json:"packageName"`
	Version     string `json:"version"`
}

type PackageRequired

type PackageRequired struct {
	PackageName  string `json:"packageName"`
	VersionRange string `json:"versionRange"`
}

type ParseError

type ParseError struct {
	Idx int
	Typ string
	Err error
}

func (ParseError) Error

func (e ParseError) Error() string

type Properties

type Properties struct {
	Packages         []Package
	PackagesRequired []PackageRequired
	Channels         []Channel
	GVKs             []GVK
	GVKsRequired     []GVKRequired
	Skips            []Skips
	SkipRanges       []SkipRange
	BundleObjects    []BundleObject

	Others []Property
}

func Parse

func Parse(in []Property) (*Properties, error)

type Property

type Property struct {
	Type  string          `json:"type"`
	Value json.RawMessage `json:"value"`
}

func Build

func Build(p interface{}) (*Property, error)

func Deduplicate

func Deduplicate(in []Property) []Property

func MustBuild

func MustBuild(p interface{}) Property

func MustBuildBundleObjectData

func MustBuildBundleObjectData(data []byte) Property

func MustBuildBundleObjectRef

func MustBuildBundleObjectRef(ref string) Property

func MustBuildChannel

func MustBuildChannel(name, replaces string) Property

func MustBuildGVK

func MustBuildGVK(group, version, kind string) Property

func MustBuildGVKRequired

func MustBuildGVKRequired(group, version, kind string) Property

func MustBuildPackage

func MustBuildPackage(name, version string) Property

func MustBuildPackageRequired

func MustBuildPackageRequired(name, versionRange string) Property

func MustBuildSkipRange

func MustBuildSkipRange(skipRange string) Property

func MustBuildSkips

func MustBuildSkips(skips string) Property

func (Property) String added in v1.17.4

func (p Property) String() string

func (Property) Validate

func (p Property) Validate() error

type SkipRange

type SkipRange string

type Skips

type Skips string

Jump to

Keyboard shortcuts

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