k8s/io/kubernetes/pkg/api/validation.ValidatePersistentVolumeClaim 示例代码

2022-03-03

以下示例是关于golang中包含validation.ValidatePersistentVolumeClaim用法的示例代码,想了解validation.ValidatePersistentVolumeClaim的具体用法?validation.ValidatePersistentVolumeClaim怎么用?validation.ValidatePersistentVolumeClaim使用的例子?那么可以参考以下10个相关示例代码来学习它的具体使用方法。

示例1:
strategy.go开发语言: Go项目名称: abhgupta代码行数: 133
59	pvc := obj.(*api.PersistentVolumeClaim)
60	return validation.ValidatePersistentVolumeClaim(pvc)
61}
81func (persistentvolumeclaimStrategy) ValidateUpdate(ctx genericapirequest.Context, obj, old runtime.Object) field.ErrorList {
82	errorList := validation.ValidatePersistentVolumeClaim(obj.(*api.PersistentVolumeClaim))
83	return append(errorList, validation.ValidatePersistentVolumeClaimUpdate(obj.(*api.PersistentVolumeClaim), old.(*api.PersistentVolumeClaim))...)
103func (persistentvolumeclaimStatusStrategy) ValidateUpdate(ctx genericapirequest.Context, obj, old runtime.Object) field.ErrorList {
104	return validation.ValidatePersistentVolumeClaimStatusUpdate(obj.(*api.PersistentVolumeClaim), old.(*api.PersistentVolumeClaim))
105}
示例2:
strategy.go开发语言: Go项目名称: amygdala代码行数: 117
52	pvc := obj.(*api.PersistentVolumeClaim)
53	return validation.ValidatePersistentVolumeClaim(pvc)
54}
71func (persistentvolumeclaimStrategy) ValidateUpdate(ctx api.Context, obj, old runtime.Object) field.ErrorList {
72	errorList := validation.ValidatePersistentVolumeClaim(obj.(*api.PersistentVolumeClaim))
73	return append(errorList, validation.ValidatePersistentVolumeClaimUpdate(obj.(*api.PersistentVolumeClaim), old.(*api.PersistentVolumeClaim))...)
93func (persistentvolumeclaimStatusStrategy) ValidateUpdate(ctx api.Context, obj, old runtime.Object) field.ErrorList {
94	return validation.ValidatePersistentVolumeClaimStatusUpdate(obj.(*api.PersistentVolumeClaim), old.(*api.PersistentVolumeClaim))
95}
示例3:
strategy.go开发语言: Go项目名称: ddysher代码行数: 126
55	pvc := obj.(*api.PersistentVolumeClaim)
56	return validation.ValidatePersistentVolumeClaim(pvc)
57}
74func (persistentvolumeclaimStrategy) ValidateUpdate(ctx genericapirequest.Context, obj, old runtime.Object) field.ErrorList {
75	errorList := validation.ValidatePersistentVolumeClaim(obj.(*api.PersistentVolumeClaim))
76	return append(errorList, validation.ValidatePersistentVolumeClaimUpdate(obj.(*api.PersistentVolumeClaim), old.(*api.PersistentVolumeClaim))...)
96func (persistentvolumeclaimStatusStrategy) ValidateUpdate(ctx genericapirequest.Context, obj, old runtime.Object) field.ErrorList {
97	return validation.ValidatePersistentVolumeClaimStatusUpdate(obj.(*api.PersistentVolumeClaim), old.(*api.PersistentVolumeClaim))
98}
示例4:
strategy.go开发语言: Go项目名称: detiber代码行数: 126
55	pvc := obj.(*api.PersistentVolumeClaim)
56	return validation.ValidatePersistentVolumeClaim(pvc)
57}
74func (persistentvolumeclaimStrategy) ValidateUpdate(ctx genericapirequest.Context, obj, old runtime.Object) field.ErrorList {
75	errorList := validation.ValidatePersistentVolumeClaim(obj.(*api.PersistentVolumeClaim))
76	return append(errorList, validation.ValidatePersistentVolumeClaimUpdate(obj.(*api.PersistentVolumeClaim), old.(*api.PersistentVolumeClaim))...)
96func (persistentvolumeclaimStatusStrategy) ValidateUpdate(ctx genericapirequest.Context, obj, old runtime.Object) field.ErrorList {
97	return validation.ValidatePersistentVolumeClaimStatusUpdate(obj.(*api.PersistentVolumeClaim), old.(*api.PersistentVolumeClaim))
98}
示例5:
strategy.go开发语言: Go项目名称: bparees代码行数: 137
61	pvc := obj.(*api.PersistentVolumeClaim)
62	return validation.ValidatePersistentVolumeClaim(pvc)
63}
82func (persistentvolumeclaimStrategy) ValidateUpdate(ctx context.Context, obj, old runtime.Object) field.ErrorList {
83	errorList := validation.ValidatePersistentVolumeClaim(obj.(*api.PersistentVolumeClaim))
84	return append(errorList, validation.ValidatePersistentVolumeClaimUpdate(obj.(*api.PersistentVolumeClaim), old.(*api.PersistentVolumeClaim))...)
107func (persistentvolumeclaimStatusStrategy) ValidateUpdate(ctx context.Context, obj, old runtime.Object) field.ErrorList {
108	return validation.ValidatePersistentVolumeClaimStatusUpdate(obj.(*api.PersistentVolumeClaim), old.(*api.PersistentVolumeClaim))
109}
示例6:
strategy.go开发语言: Go项目名称: byxorna代码行数: 137
61	pvc := obj.(*api.PersistentVolumeClaim)
62	return validation.ValidatePersistentVolumeClaim(pvc)
63}
82func (persistentvolumeclaimStrategy) ValidateUpdate(ctx context.Context, obj, old runtime.Object) field.ErrorList {
83	errorList := validation.ValidatePersistentVolumeClaim(obj.(*api.PersistentVolumeClaim))
84	return append(errorList, validation.ValidatePersistentVolumeClaimUpdate(obj.(*api.PersistentVolumeClaim), old.(*api.PersistentVolumeClaim))...)
107func (persistentvolumeclaimStatusStrategy) ValidateUpdate(ctx context.Context, obj, old runtime.Object) field.ErrorList {
108	return validation.ValidatePersistentVolumeClaimStatusUpdate(obj.(*api.PersistentVolumeClaim), old.(*api.PersistentVolumeClaim))
109}
示例7:
strategy.go开发语言: Go项目名称: cjcullen代码行数: 121
53	pvc := obj.(*api.PersistentVolumeClaim)
54	return validation.ValidatePersistentVolumeClaim(pvc)
55}
72func (persistentvolumeclaimStrategy) ValidateUpdate(ctx api.Context, obj, old runtime.Object) field.ErrorList {
73	errorList := validation.ValidatePersistentVolumeClaim(obj.(*api.PersistentVolumeClaim))
74	return append(errorList, validation.ValidatePersistentVolumeClaimUpdate(obj.(*api.PersistentVolumeClaim), old.(*api.PersistentVolumeClaim))...)
94func (persistentvolumeclaimStatusStrategy) ValidateUpdate(ctx api.Context, obj, old runtime.Object) field.ErrorList {
95	return validation.ValidatePersistentVolumeClaimStatusUpdate(obj.(*api.PersistentVolumeClaim), old.(*api.PersistentVolumeClaim))
96}
示例8:
strategy.go开发语言: Go项目名称: cloud-zuiwanyuan代码行数: 120
52	pvc := obj.(*api.PersistentVolumeClaim)
53	return validation.ValidatePersistentVolumeClaim(pvc)
54}
71func (persistentvolumeclaimStrategy) ValidateUpdate(ctx api.Context, obj, old runtime.Object) field.ErrorList {
72	errorList := validation.ValidatePersistentVolumeClaim(obj.(*api.PersistentVolumeClaim))
73	return append(errorList, validation.ValidatePersistentVolumeClaimUpdate(obj.(*api.PersistentVolumeClaim), old.(*api.PersistentVolumeClaim))...)
93func (persistentvolumeclaimStatusStrategy) ValidateUpdate(ctx api.Context, obj, old runtime.Object) field.ErrorList {
94	return validation.ValidatePersistentVolumeClaimStatusUpdate(obj.(*api.PersistentVolumeClaim), old.(*api.PersistentVolumeClaim))
95}
示例9:
strategy.go开发语言: Go项目名称: csrwng代码行数: 137
61	pvc := obj.(*api.PersistentVolumeClaim)
62	return validation.ValidatePersistentVolumeClaim(pvc)
63}
82func (persistentvolumeclaimStrategy) ValidateUpdate(ctx context.Context, obj, old runtime.Object) field.ErrorList {
83	errorList := validation.ValidatePersistentVolumeClaim(obj.(*api.PersistentVolumeClaim))
84	return append(errorList, validation.ValidatePersistentVolumeClaimUpdate(obj.(*api.PersistentVolumeClaim), old.(*api.PersistentVolumeClaim))...)
107func (persistentvolumeclaimStatusStrategy) ValidateUpdate(ctx context.Context, obj, old runtime.Object) field.ErrorList {
108	return validation.ValidatePersistentVolumeClaimStatusUpdate(obj.(*api.PersistentVolumeClaim), old.(*api.PersistentVolumeClaim))
109}
示例10:
examples_test.go开发语言: Go项目名称: abhgupta代码行数: 464
83		}
84		errors = validation.ValidatePersistentVolumeClaim(t)
85	case *api.PodTemplate:

本文地址:https://www.itbaoku.cn/snippets/415897.html