Documentation
¶
Index ¶
- func NewREST(registry Registry) apiserver.RESTStorage
- type REST
- func (r *REST) Create(ctx kapi.Context, obj runtime.Object) (runtime.Object, error)
- func (r *REST) Delete(ctx kapi.Context, id string) (runtime.Object, error)
- func (r *REST) Get(ctx kapi.Context, id string) (runtime.Object, error)
- func (r *REST) List(ctx kapi.Context, selector, fields labels.Selector) (runtime.Object, error)
- func (r *REST) New() runtime.Object
- func (*REST) NewList() runtime.Object
- func (r *REST) Update(ctx kapi.Context, obj runtime.Object) (runtime.Object, bool, error)
- func (r *REST) Watch(ctx kapi.Context, label, field labels.Selector, resourceVersion string) (watch.Interface, error)
- type Registry
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewREST ¶
func NewREST(registry Registry) apiserver.RESTStorage
NewREST creates a new REST for builds.
Types ¶
type REST ¶
type REST struct {
// contains filtered or unexported fields
}
REST implements the RESTStorage interface in terms of an Registry.
type Registry ¶
type Registry interface {
// ListBuilds obtains list of builds that match a selector.
ListBuilds(ctx kapi.Context, labels labels.Selector) (*api.BuildList, error)
// GetBuild retrieves a specific build.
GetBuild(ctx kapi.Context, id string) (*api.Build, error)
// CreateBuild creates a new build.
CreateBuild(ctx kapi.Context, build *api.Build) error
// UpdateBuild updates a build.
UpdateBuild(ctx kapi.Context, build *api.Build) error
// DeleteBuild deletes a build.
DeleteBuild(ctx kapi.Context, id string) error
// WatchBuilds watches builds.
WatchBuilds(ctx kapi.Context, label, field labels.Selector, resourceVersion string) (watch.Interface, error)
}
Registry is an interface for things that know how to store Builds.
Click to show internal directories.
Click to hide internal directories.