Documentation
¶
Index ¶
- Variables
- func Compare(a, b interface{}) int
- func MapAccessOutput(e compdesc.AccessSpec) []string
- func MapMetaOutput(e interface{}) []string
- func MapNodeOutput(e interface{}) []string
- func MapToCompHandlerOptions(opts ...Option) comphdlr.Options
- func NewTypeHandler(octx clictx.OCM, oopts *output.Options, repobase ocm.Repository, ...) (utils.TypeHandler, error)
- func NodeMapping(n int) output.TreeOutputOption
- func NodeTitle(obj *tree.TreeObject) string
- type ElementFilter
- type Manifest
- type Object
- type Objects
- type Option
- type Options
- type TypeHandler
Constants ¶
This section is empty.
Variables ¶
View Source
var AccessOutput = []string{"ACCESSTYPE", "ACCESSSPEC"}
View Source
var MetaOutput = []string{"NAME", "VERSION", "IDENTITY"}
View Source
var Sort = processing.Sort(Compare)
Sort is a processing chain sorting original objects provided by type handler.
Functions ¶
func MapAccessOutput ¶
func MapAccessOutput(e compdesc.AccessSpec) []string
func MapMetaOutput ¶
func MapMetaOutput(e interface{}) []string
func MapNodeOutput ¶
func MapNodeOutput(e interface{}) []string
func MapToCompHandlerOptions ¶
func NewTypeHandler ¶
func NewTypeHandler(octx clictx.OCM, oopts *output.Options, repobase ocm.Repository, session ocm.Session, kind string, compspecs []string, elemaccess func(ocm.ComponentVersionAccess) compdesc.ElementAccessor, hopts ...Option) (utils.TypeHandler, error)
func NodeMapping ¶
func NodeMapping(n int) output.TreeOutputOption
func NodeTitle ¶
func NodeTitle(obj *tree.TreeObject) string
Types ¶
type ElementFilter ¶
type ElementFilter interface {
Accept(e compdesc.ElementMetaAccessor) bool
}
type Manifest ¶
type Manifest struct { History common.History `json:"context"` Element compdesc.ElementMetaAccessor `json:"element"` }
type Object ¶
type Object struct { History common.History Version ocm.ComponentVersionAccess VersionId metav1.Identity Spec metav1.Identity Id metav1.Identity Node *common.NameVersion Element compdesc.ElementMetaAccessor }
func (*Object) AsManifest ¶
func (o *Object) AsManifest() interface{}
func (*Object) GetHistory ¶
func (*Object) IsNode ¶
func (o *Object) IsNode() *common.NameVersion
type Option ¶
type Option interface {
ApplyToElemHandler(handler *TypeHandler)
}
func ForceEmpty ¶
func LatestOnly ¶
func WithFilter ¶
func WithFilter(fi ElementFilter) Option
func WithVersionConstraints ¶
func WithVersionConstraints(c []*semver.Constraints) Option
type Options ¶
type Options []Option
func OptionsFor ¶
func OptionsFor(o options.OptionSetProvider) Options
func (Options) ApplyToElemHandler ¶
func (o Options) ApplyToElemHandler(handler *TypeHandler)
type TypeHandler ¶
type TypeHandler struct {
// contains filtered or unexported fields
}
func (*TypeHandler) Close ¶
func (h *TypeHandler) Close() error
func (*TypeHandler) SetFilter ¶
func (h *TypeHandler) SetFilter(f ElementFilter)
Click to show internal directories.
Click to hide internal directories.