func (c *images) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
	return c.client.Delete().
		Namespace(c.ns).
		Resource("images").
		Name(name).
		Body(&opts).
		Do(ctx).
		Error()
}
Delete takes name of the image and deletes it. Returns an error if one occurs.
package v1alpha2
import (
	"context"
	"time"
	v1alpha2 "github.com/pivotal/kpack/pkg/apis/build/v1alpha2"
	scheme "github.com/pivotal/kpack/pkg/client/clientset/versioned/scheme"
	v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
	types "k8s.io/apimachinery/pkg/types"
	watch "k8s.io/apimachinery/pkg/watch"
	rest "k8s.io/client-go/rest"
)
type ImagesGetter interface {
	Images(namespace string) ImageInterface
}
type ImageInterface interface {
	Create(ctx context.Context, image *v1alpha2.Image, opts v1.CreateOptions) (*v1alpha2.Image, error)
	Update(ctx context.Context, image *v1alpha2.Image, opts v1.UpdateOptions) (*v1alpha2.Image, error)
	UpdateStatus(ctx context.Context, image *v1alpha2.Image, opts v1.UpdateOptions) (*v1alpha2.Image, error)
	Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
	DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
	Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha2.Image, error)
	List(ctx context.Context, opts v1.ListOptions) (*v1alpha2.ImageList, error)
	Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
	Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha2.Image, err error)
	ImageExpansion
}
type images struct {
	client rest.Interface
	ns     string
}
func newImages(c *KpackV1alpha2Client, namespace string) *images {
	return &images{
		client: c.RESTClient(),
		ns:     namespace,
	}
}
func (c *images) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha2.Image, err error) {
	result = &v1alpha2.Image{}
	err = c.client.Get().
		Namespace(c.ns).
		Resource("images").
		Name(name).
		VersionedParams(&options, scheme.ParameterCodec).
		Do(ctx).
		Into(result)
	return
}
func (c *images) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha2.ImageList, err error) {
	var timeout time.Duration
	if opts.TimeoutSeconds != nil {
		timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
	}
	result = &v1alpha2.ImageList{}
	err = c.client.Get().
		Namespace(c.ns).
		Resource("images").
		VersionedParams(&opts, scheme.ParameterCodec).
		Timeout(timeout).
		Do(ctx).
		Into(result)
	return
}
func (c *images) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
	var timeout time.Duration
	if opts.TimeoutSeconds != nil {
		timeout = time.Duration(*opts.TimeoutSeconds) * time.Second
	}
	opts.Watch = true
	return c.client.Get().
		Namespace(c.ns).
		Resource("images").
		VersionedParams(&opts, scheme.ParameterCodec).
		Timeout(timeout).
		Watch(ctx)
}
func (c *images) Create(ctx context.Context, image *v1alpha2.Image, opts v1.CreateOptions) (result *v1alpha2.Image, err error) {
	result = &v1alpha2.Image{}
	err = c.client.Post().
		Namespace(c.ns).
		Resource("images").
		VersionedParams(&opts, scheme.ParameterCodec).
		Body(image).
		Do(ctx).
		Into(result)
	return
}
func (c *images) Update(ctx context.Context, image *v1alpha2.Image, opts v1.UpdateOptions) (result *v1alpha2.Image, err error) {
	result = &v1alpha2.Image{}
	err = c.client.Put().
		Namespace(c.ns).
		Resource("images").
		Name(image.Name).
		VersionedParams(&opts, scheme.ParameterCodec).
		Body(image).
		Do(ctx).
		Into(result)
	return
}
func (c *images) UpdateStatus(ctx context.Context, image *v1alpha2.Image, opts v1.UpdateOptions) (result *v1alpha2.Image, err error) {
	result = &v1alpha2.Image{}
	err = c.client.Put().
		Namespace(c.ns).
		Resource("images").
		Name(image.Name).
		SubResource("status").
		VersionedParams(&opts, scheme.ParameterCodec).
		Body(image).
		Do(ctx).
		Into(result)
	return
}