Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FormatBundle ¶
type FormatBundle struct { ByAlias map[string][]*FormatContainer ByGroupKind map[schema.GroupKind][]*FormatContainer ByName map[string]*FormatContainer SearchPaths []string }
func (*FormatBundle) ToPrinter ¶
func (fb *FormatBundle) ToPrinter(mapping *meta.RESTMapping, opts Options) (cliprinters.ResourcePrinterFunc, error)
ToPrinter selects the best resource printer based on GVK and formatting options.
type FormatContainer ¶
type FormatContainer struct { *v1alpha1.ShowFormat runtime.Decoder Path string // contains filtered or unexported fields }
func (*FormatContainer) ToPrinter ¶
func (fc *FormatContainer) ToPrinter(opts Options) (cliprinters.ResourcePrinterFunc, error)
type NoCompatibleConfigError ¶
type NoCompatibleConfigError struct { GroupKind schema.GroupKind AllowedFormats []string Paths []string }
func (NoCompatibleConfigError) Error ¶
func (e NoCompatibleConfigError) Error() string
type Options ¶
type Options struct { // AllowedFormats is a map of allowed formats. The value is ignored. AllowedFormats map[string]bool // NoHeaders is whether headers should be printed or not. NoHeaders bool }
Options captures formatting options.
func (Options) Allows ¶
func (opts Options) Allows(fc *FormatContainer) bool
Allows returns whether the format container is allowed by options or not.
Click to show internal directories.
Click to hide internal directories.