describe

package
v1.14.0-alpha.2 Latest Latest
Warning

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

Go to latest
Published: Jan 29, 2019 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// LoadBalancerWidth is the width how we describe load balancer
	LoadBalancerWidth = 16

	// LabelNodeRolePrefix is a label prefix for node roles
	// It's copied over to here until it's merged in core: https://github.com/kubernetes/kubernetes/pull/39112
	LabelNodeRolePrefix = "node-role.kubernetes.io/"

	// NodeLabelRole specifies the role of a node
	NodeLabelRole = "kubernetes.io/role"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Describer

type Describer interface {
	Describe(namespace, name string, describerSettings DescriberSettings) (output string, err error)
}

Describer generates output for the named resource or an error if the output could not be generated. Implementers typically abstract the retrieval of the named object from a remote server.

type DescriberFunc

type DescriberFunc func(restClientGetter genericclioptions.RESTClientGetter, mapping *meta.RESTMapping) (Describer, error)

DescriberFunc gives a way to display the specified RESTMapping type

type DescriberSettings

type DescriberSettings struct {
	ShowEvents bool
}

DescriberSettings holds display configuration for each object describer to control what is printed.

type ErrNoDescriber

type ErrNoDescriber struct {
	Types []string
}

ErrNoDescriber is a structured error indicating the provided object or objects cannot be described.

func (ErrNoDescriber) Error

func (e ErrNoDescriber) Error() string

Error implements the error interface.

type ObjectDescriber

type ObjectDescriber interface {
	DescribeObject(object interface{}, extra ...interface{}) (output string, err error)
}

ObjectDescriber is an interface for displaying arbitrary objects with extra information. Use when an object is in hand (on disk, or already retrieved). Implementers may ignore the additional information passed on extra, or use it by default. ObjectDescribers may return ErrNoDescriber if no suitable describer is found.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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