Re-generate extract functions

Kubernetes-commit: a24e8acc32d7c0380a7b2c8a2f500b48891a9987
This commit is contained in:
Joe Betz
2021-03-19 15:28:20 -07:00
committed by Kubernetes Publisher
parent d3fbdeba9a
commit 0fd603dad0
98 changed files with 1176 additions and 98 deletions

View File

@@ -59,8 +59,19 @@ func Ingress(name, namespace string) *IngressApplyConfiguration {
// applied if another fieldManager has updated or force applied any of the previously applied fields.
// Experimental!
func ExtractIngress(ingress *networkingv1beta1.Ingress, fieldManager string) (*IngressApplyConfiguration, error) {
return extractIngress(ingress, fieldManager, "")
}
// ExtractIngressStatus is the same as ExtractIngress except
// that it extracts the status subresource applied configuration.
// Experimental!
func ExtractIngressStatus(ingress *networkingv1beta1.Ingress, fieldManager string) (*IngressApplyConfiguration, error) {
return extractIngress(ingress, fieldManager, "status")
}
func extractIngress(ingress *networkingv1beta1.Ingress, fieldManager string, subresource string) (*IngressApplyConfiguration, error) {
b := &IngressApplyConfiguration{}
err := managedfields.ExtractInto(ingress, internal.Parser().Type("io.k8s.api.networking.v1beta1.Ingress"), fieldManager, b)
err := managedfields.ExtractInto(ingress, internal.Parser().Type("io.k8s.api.networking.v1beta1.Ingress"), fieldManager, b, subresource)
if err != nil {
return nil, err
}