Documentation ¶
Index ¶
- func Create(info *resource.Info, namespace string, obj runtime.Object) (runtime.Object, error)
- func CreateMessage(labels map[string]string) string
- func NewPrintErrorAfter(mapper meta.RESTMapper, errs io.Writer) func(*resource.Info, error) bool
- func NoOp(info *resource.Info, namespace string, obj runtime.Object) (runtime.Object, error)
- type AfterFunc
- type Bulk
- type BulkAction
- func (b *BulkAction) BindForAction(flags *pflag.FlagSet)
- func (b *BulkAction) BindForOutput(flags *pflag.FlagSet)
- func (b *BulkAction) Compact()
- func (b *BulkAction) DefaultIndent() string
- func (b *BulkAction) Run(list *kapi.List, namespace string) []error
- func (b *BulkAction) ShouldPrint() bool
- func (b *BulkAction) Verbose() bool
- func (b BulkAction) WithMessage(action, individual string) Runner
- type Mapper
- type OpFunc
- type RetryFunc
- type Runner
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateMessage ¶
func NewPrintErrorAfter ¶ added in v1.0.7
Types ¶
type AfterFunc ¶ added in v1.0.8
AfterFunc takes an info and an error, and returns true if processing should stop.
func HaltOnError ¶ added in v1.0.8
func NewPrintNameOrErrorAfterIndent ¶ added in v1.0.7
type BulkAction ¶
type BulkAction struct { // required setup Bulk Bulk Out, ErrOut io.Writer // flags Output string DryRun bool StopOnError bool // output modifiers Action string }
func (*BulkAction) BindForAction ¶
func (b *BulkAction) BindForAction(flags *pflag.FlagSet)
BindForAction sets flags on this action for when setting -o should only change how the operation results are displayed. Passing -o is changing the default output format.
func (*BulkAction) BindForOutput ¶
func (b *BulkAction) BindForOutput(flags *pflag.FlagSet)
BindForOutput sets flags on this action for when setting -o will not execute the action (the point of the action is primarily to generate the output). Passing -o is asking for output, not execution.
func (*BulkAction) Compact ¶
func (b *BulkAction) Compact()
Compact sets the output to a minimal set
func (*BulkAction) DefaultIndent ¶
func (b *BulkAction) DefaultIndent() string
func (*BulkAction) ShouldPrint ¶
func (b *BulkAction) ShouldPrint() bool
ShouldPrint returns true if an external printer should handle this action instead of execution.
func (*BulkAction) Verbose ¶
func (b *BulkAction) Verbose() bool
func (BulkAction) WithMessage ¶
func (b BulkAction) WithMessage(action, individual string) Runner
type Mapper ¶
type Mapper interface { meta.RESTMapper InfoForObject(obj runtime.Object, preferredGVKs []unversioned.GroupVersionKind) (*resource.Info, error) }
Mapper is an interface testability that is equivalent to resource.Mapper