Esempio n. 1
0
func DeepCopy_v1_Image(in Image, out *Image, c *conversion.Cloner) error {
	if err := unversioned.DeepCopy_unversioned_TypeMeta(in.TypeMeta, &out.TypeMeta, c); err != nil {
		return err
	}
	if err := api_v1.DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
		return err
	}
	out.DockerImageReference = in.DockerImageReference
	if err := runtime.DeepCopy_runtime_RawExtension(in.DockerImageMetadata, &out.DockerImageMetadata, c); err != nil {
		return err
	}
	out.DockerImageMetadataVersion = in.DockerImageMetadataVersion
	out.DockerImageManifest = in.DockerImageManifest
	if in.DockerImageLayers != nil {
		in, out := in.DockerImageLayers, &out.DockerImageLayers
		*out = make([]ImageLayer, len(in))
		for i := range in {
			if err := DeepCopy_v1_ImageLayer(in[i], &(*out)[i], c); err != nil {
				return err
			}
		}
	} else {
		out.DockerImageLayers = nil
	}
	return nil
}
Esempio n. 2
0
func DeepCopy_v1_AuthorizationAttributes(in AuthorizationAttributes, out *AuthorizationAttributes, c *conversion.Cloner) error {
	out.Namespace = in.Namespace
	out.Verb = in.Verb
	out.Group = in.Group
	out.Version = in.Version
	out.Resource = in.Resource
	out.ResourceName = in.ResourceName
	if err := runtime.DeepCopy_runtime_RawExtension(in.Content, &out.Content, c); err != nil {
		return err
	}
	return nil
}
Esempio n. 3
0
func DeepCopy_v1_Image(in Image, out *Image, c *conversion.Cloner) error {
	if err := unversioned.DeepCopy_unversioned_TypeMeta(in.TypeMeta, &out.TypeMeta, c); err != nil {
		return err
	}
	if err := api_v1.DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
		return err
	}
	out.DockerImageReference = in.DockerImageReference
	if err := runtime.DeepCopy_runtime_RawExtension(in.DockerImageMetadata, &out.DockerImageMetadata, c); err != nil {
		return err
	}
	out.DockerImageMetadataVersion = in.DockerImageMetadataVersion
	out.DockerImageManifest = in.DockerImageManifest
	if in.DockerImageLayers != nil {
		in, out := in.DockerImageLayers, &out.DockerImageLayers
		*out = make([]ImageLayer, len(in))
		for i := range in {
			if err := DeepCopy_v1_ImageLayer(in[i], &(*out)[i], c); err != nil {
				return err
			}
		}
	} else {
		out.DockerImageLayers = nil
	}
	if in.Signatures != nil {
		in, out := in.Signatures, &out.Signatures
		*out = make([]ImageSignature, len(in))
		for i := range in {
			if err := DeepCopy_v1_ImageSignature(in[i], &(*out)[i], c); err != nil {
				return err
			}
		}
	} else {
		out.Signatures = nil
	}
	if in.DockerImageSignatures != nil {
		in, out := in.DockerImageSignatures, &out.DockerImageSignatures
		*out = make([][]byte, len(in))
		for i := range in {
			if newVal, err := c.DeepCopy(in[i]); err != nil {
				return err
			} else {
				(*out)[i] = newVal.([]byte)
			}
		}
	} else {
		out.DockerImageSignatures = nil
	}
	out.DockerImageManifestMediaType = in.DockerImageManifestMediaType
	out.DockerImageConfig = in.DockerImageConfig
	return nil
}
func DeepCopy_v1_Image(in interface{}, out interface{}, c *conversion.Cloner) error {
	{
		in := in.(*Image)
		out := out.(*Image)
		out.TypeMeta = in.TypeMeta
		if err := api_v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil {
			return err
		}
		out.DockerImageReference = in.DockerImageReference
		if err := runtime.DeepCopy_runtime_RawExtension(&in.DockerImageMetadata, &out.DockerImageMetadata, c); err != nil {
			return err
		}
		out.DockerImageMetadataVersion = in.DockerImageMetadataVersion
		out.DockerImageManifest = in.DockerImageManifest
		if in.DockerImageLayers != nil {
			in, out := &in.DockerImageLayers, &out.DockerImageLayers
			*out = make([]ImageLayer, len(*in))
			for i := range *in {
				(*out)[i] = (*in)[i]
			}
		} else {
			out.DockerImageLayers = nil
		}
		if in.Signatures != nil {
			in, out := &in.Signatures, &out.Signatures
			*out = make([]ImageSignature, len(*in))
			for i := range *in {
				if err := DeepCopy_v1_ImageSignature(&(*in)[i], &(*out)[i], c); err != nil {
					return err
				}
			}
		} else {
			out.Signatures = nil
		}
		if in.DockerImageSignatures != nil {
			in, out := &in.DockerImageSignatures, &out.DockerImageSignatures
			*out = make([][]byte, len(*in))
			for i := range *in {
				if newVal, err := c.DeepCopy(&(*in)[i]); err != nil {
					return err
				} else {
					(*out)[i] = *newVal.(*[]byte)
				}
			}
		} else {
			out.DockerImageSignatures = nil
		}
		out.DockerImageManifestMediaType = in.DockerImageManifestMediaType
		out.DockerImageConfig = in.DockerImageConfig
		return nil
	}
}
Esempio n. 5
0
func DeepCopy_v1_Action(in interface{}, out interface{}, c *conversion.Cloner) error {
	{
		in := in.(*Action)
		out := out.(*Action)
		out.Namespace = in.Namespace
		out.Verb = in.Verb
		out.Group = in.Group
		out.Version = in.Version
		out.Resource = in.Resource
		out.ResourceName = in.ResourceName
		if err := runtime.DeepCopy_runtime_RawExtension(&in.Content, &out.Content, c); err != nil {
			return err
		}
		return nil
	}
}
Esempio n. 6
0
func DeepCopy_v1_PolicyRule(in interface{}, out interface{}, c *conversion.Cloner) error {
	{
		in := in.(*PolicyRule)
		out := out.(*PolicyRule)
		if in.Verbs != nil {
			in, out := &in.Verbs, &out.Verbs
			*out = make([]string, len(*in))
			copy(*out, *in)
		} else {
			out.Verbs = nil
		}
		if err := runtime.DeepCopy_runtime_RawExtension(&in.AttributeRestrictions, &out.AttributeRestrictions, c); err != nil {
			return err
		}
		if in.APIGroups != nil {
			in, out := &in.APIGroups, &out.APIGroups
			*out = make([]string, len(*in))
			copy(*out, *in)
		} else {
			out.APIGroups = nil
		}
		if in.Resources != nil {
			in, out := &in.Resources, &out.Resources
			*out = make([]string, len(*in))
			copy(*out, *in)
		} else {
			out.Resources = nil
		}
		if in.ResourceNames != nil {
			in, out := &in.ResourceNames, &out.ResourceNames
			*out = make([]string, len(*in))
			copy(*out, *in)
		} else {
			out.ResourceNames = nil
		}
		if in.NonResourceURLsSlice != nil {
			in, out := &in.NonResourceURLsSlice, &out.NonResourceURLsSlice
			*out = make([]string, len(*in))
			copy(*out, *in)
		} else {
			out.NonResourceURLsSlice = nil
		}
		return nil
	}
}
Esempio n. 7
0
func DeepCopy_v1_Template(in Template, out *Template, c *conversion.Cloner) error {
	if err := unversioned.DeepCopy_unversioned_TypeMeta(in.TypeMeta, &out.TypeMeta, c); err != nil {
		return err
	}
	if err := api_v1.DeepCopy_v1_ObjectMeta(in.ObjectMeta, &out.ObjectMeta, c); err != nil {
		return err
	}
	out.Message = in.Message
	if in.Objects != nil {
		in, out := in.Objects, &out.Objects
		*out = make([]runtime.RawExtension, len(in))
		for i := range in {
			if err := runtime.DeepCopy_runtime_RawExtension(in[i], &(*out)[i], c); err != nil {
				return err
			}
		}
	} else {
		out.Objects = nil
	}
	if in.Parameters != nil {
		in, out := in.Parameters, &out.Parameters
		*out = make([]Parameter, len(in))
		for i := range in {
			if err := DeepCopy_v1_Parameter(in[i], &(*out)[i], c); err != nil {
				return err
			}
		}
	} else {
		out.Parameters = nil
	}
	if in.ObjectLabels != nil {
		in, out := in.ObjectLabels, &out.ObjectLabels
		*out = make(map[string]string)
		for key, val := range in {
			(*out)[key] = val
		}
	} else {
		out.ObjectLabels = nil
	}
	return nil
}
Esempio n. 8
0
func DeepCopy_v1alpha1_PolicyRule(in PolicyRule, out *PolicyRule, c *conversion.Cloner) error {
	if in.Verbs != nil {
		in, out := in.Verbs, &out.Verbs
		*out = make([]string, len(in))
		copy(*out, in)
	} else {
		out.Verbs = nil
	}
	if err := runtime.DeepCopy_runtime_RawExtension(in.AttributeRestrictions, &out.AttributeRestrictions, c); err != nil {
		return err
	}
	if in.APIGroups != nil {
		in, out := in.APIGroups, &out.APIGroups
		*out = make([]string, len(in))
		copy(*out, in)
	} else {
		out.APIGroups = nil
	}
	if in.Resources != nil {
		in, out := in.Resources, &out.Resources
		*out = make([]string, len(in))
		copy(*out, in)
	} else {
		out.Resources = nil
	}
	if in.ResourceNames != nil {
		in, out := in.ResourceNames, &out.ResourceNames
		*out = make([]string, len(in))
		copy(*out, in)
	} else {
		out.ResourceNames = nil
	}
	if in.NonResourceURLs != nil {
		in, out := in.NonResourceURLs, &out.NonResourceURLs
		*out = make([]string, len(in))
		copy(*out, in)
	} else {
		out.NonResourceURLs = nil
	}
	return nil
}
func DeepCopy_v1_Template(in interface{}, out interface{}, c *conversion.Cloner) error {
	{
		in := in.(*Template)
		out := out.(*Template)
		out.TypeMeta = in.TypeMeta
		if err := api_v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil {
			return err
		}
		out.Message = in.Message
		if in.Objects != nil {
			in, out := &in.Objects, &out.Objects
			*out = make([]runtime.RawExtension, len(*in))
			for i := range *in {
				if err := runtime.DeepCopy_runtime_RawExtension(&(*in)[i], &(*out)[i], c); err != nil {
					return err
				}
			}
		} else {
			out.Objects = nil
		}
		if in.Parameters != nil {
			in, out := &in.Parameters, &out.Parameters
			*out = make([]Parameter, len(*in))
			for i := range *in {
				(*out)[i] = (*in)[i]
			}
		} else {
			out.Parameters = nil
		}
		if in.ObjectLabels != nil {
			in, out := &in.ObjectLabels, &out.ObjectLabels
			*out = make(map[string]string)
			for key, val := range *in {
				(*out)[key] = val
			}
		} else {
			out.ObjectLabels = nil
		}
		return nil
	}
}