package persistentvolume
import "k8s.io/kubernetes/pkg/registry/persistentvolume"
Index ¶
- Variables
- func MatchPersistentVolumes(label labels.Selector, field fields.Selector) generic.Matcher
- func PersistentVolumeToSelectableFields(persistentvolume *api.PersistentVolume) labels.Set
- type Registry
Variables ¶
var StatusStrategy = persistentvolumeStatusStrategy{Strategy}
var Strategy = persistentvolumeStrategy{api.Scheme, api.SimpleNameGenerator}
Strategy is the default logic that applies when creating and updating PersistentVolume objects via the REST API.
Functions ¶
func MatchPersistentVolumes ¶
MatchPersistentVolume returns a generic matcher for a given label and field selector.
func PersistentVolumeToSelectableFields ¶
func PersistentVolumeToSelectableFields(persistentvolume *api.PersistentVolume) labels.Set
PersistentVolumeToSelectableFields returns a label set that represents the object TODO: fields are not labels, and the validation rules for them do not apply.
Types ¶
type Registry ¶
type Registry interface { // ListPersistentVolumes obtains a list of persistentVolumes having labels which match selector. ListPersistentVolumes(ctx api.Context, selector labels.Selector) (*api.PersistentVolumeList, error) // Watch for new/changed/deleted persistentVolumes WatchPersistentVolumes(ctx api.Context, label labels.Selector, field fields.Selector, resourceVersion string) (watch.Interface, error) // Get a specific persistentVolume GetPersistentVolume(ctx api.Context, persistentVolumeID string) (*api.PersistentVolume, error) // Create a persistentVolume based on a specification. CreatePersistentVolume(ctx api.Context, persistentVolume *api.PersistentVolume) error // Update an existing persistentVolume UpdatePersistentVolume(ctx api.Context, persistentVolume *api.PersistentVolume) error // Delete an existing persistentVolume DeletePersistentVolume(ctx api.Context, persistentVolumeID string) error }
Registry is an interface implemented by things that know how to store PersistentVolume objects.
func NewRegistry ¶
func NewRegistry(s rest.StandardStorage) Registry
NewRegistry returns a new Registry interface for the given Storage. Any mismatched types will panic.
Source Files ¶
doc.go registry.go rest.go
Directories ¶
Path | Synopsis |
---|---|
pkg/registry/persistentvolume/etcd |
- Version
- v0.16.2
- Published
- May 4, 2015
- Platform
- js/wasm
- Imports
- 10 packages
- Last checked
- 1 minute ago –
Tools for package owners.