Documentation ¶
Overview ¶
Package delete provides the delete command, as well as subcommands for deleting specific resources and resource types.
Index ¶
- func Command(builder Builder) *cobra.Command
- type Builder
- type DefaultDeleter
- func (d *DefaultDeleter) DeleteResources(ctx context.Context, kind model.Kind, ids []string) error
- func (d *DefaultDeleter) DeleteResourcesFromFiles(ctx context.Context, filenames []string) ([]*model.AnyResourceStatus, error)
- func (d *DefaultDeleter) DeleteResourcesFromReader(ctx context.Context, reader io.Reader) ([]*model.AnyResourceStatus, error)
- type Deleter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Builder ¶
type Builder interface { // Build returns a new Deleter. BuildDeleter(ctx context.Context) (Deleter, error) }
Builder is an interface for building a Deleter.
type DefaultDeleter ¶
type DefaultDeleter struct {
// contains filtered or unexported fields
}
DefaultDeleter is the default implementation of Deleter.
func NewDeleter ¶
func NewDeleter(client client.BindPlane) *DefaultDeleter
NewDeleter returns a new Deleter.
func (*DefaultDeleter) DeleteResources ¶
DeleteResources deletes resources.
func (*DefaultDeleter) DeleteResourcesFromFiles ¶ added in v1.24.0
func (d *DefaultDeleter) DeleteResourcesFromFiles(ctx context.Context, filenames []string) ([]*model.AnyResourceStatus, error)
DeleteResourcesFromFiles deletes all resources from a file.
func (*DefaultDeleter) DeleteResourcesFromReader ¶ added in v1.24.0
func (d *DefaultDeleter) DeleteResourcesFromReader(ctx context.Context, reader io.Reader) ([]*model.AnyResourceStatus, error)
DeleteResourcesFromReader applies all resources from a reader.
type Deleter ¶
type Deleter interface { // DeleteResources deletes resources. DeleteResources(ctx context.Context, kind model.Kind, ids []string) error // DeleteResourcesFromFile deletes resources from a list of files. DeleteResourcesFromFiles(ctx context.Context, filenames []string) ([]*model.AnyResourceStatus, error) // DeleteResourcesFromReader deletes all resources from a reader. DeleteResourcesFromReader(ctx context.Context, reader io.Reader) ([]*model.AnyResourceStatus, error) }
Deleter is an interface for deleting resources.
Click to show internal directories.
Click to hide internal directories.