• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

Golang v1.DeepCopy_v1_LocalObjectReference函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Golang中k8s/io/kubernetes/pkg/api/v1.DeepCopy_v1_LocalObjectReference函数的典型用法代码示例。如果您正苦于以下问题:Golang DeepCopy_v1_LocalObjectReference函数的具体用法?Golang DeepCopy_v1_LocalObjectReference怎么用?Golang DeepCopy_v1_LocalObjectReference使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了DeepCopy_v1_LocalObjectReference函数的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Golang代码示例。

示例1: DeepCopy_v1_SecretSpec

func DeepCopy_v1_SecretSpec(in SecretSpec, out *SecretSpec, c *conversion.Cloner) error {
	if err := api_v1.DeepCopy_v1_LocalObjectReference(in.SecretSource, &out.SecretSource, c); err != nil {
		return err
	}
	out.MountPath = in.MountPath
	return nil
}
开发者ID:jdnieto,项目名称:origin,代码行数:7,代码来源:deep_copy_generated.go


示例2: DeepCopy_v1_SourceBuildStrategy

func DeepCopy_v1_SourceBuildStrategy(in SourceBuildStrategy, out *SourceBuildStrategy, c *conversion.Cloner) error {
	if err := api_v1.DeepCopy_v1_ObjectReference(in.From, &out.From, c); err != nil {
		return err
	}
	if in.PullSecret != nil {
		in, out := in.PullSecret, &out.PullSecret
		*out = new(api_v1.LocalObjectReference)
		if err := api_v1.DeepCopy_v1_LocalObjectReference(*in, *out, c); err != nil {
			return err
		}
	} else {
		out.PullSecret = nil
	}
	if in.Env != nil {
		in, out := in.Env, &out.Env
		*out = make([]api_v1.EnvVar, len(in))
		for i := range in {
			if err := api_v1.DeepCopy_v1_EnvVar(in[i], &(*out)[i], c); err != nil {
				return err
			}
		}
	} else {
		out.Env = nil
	}
	out.Scripts = in.Scripts
	out.Incremental = in.Incremental
	out.ForcePull = in.ForcePull
	return nil
}
开发者ID:jdnieto,项目名称:origin,代码行数:29,代码来源:deep_copy_generated.go


示例3: DeepCopy_v1_ImageSource

func DeepCopy_v1_ImageSource(in ImageSource, out *ImageSource, c *conversion.Cloner) error {
	if err := api_v1.DeepCopy_v1_ObjectReference(in.From, &out.From, c); err != nil {
		return err
	}
	if in.Paths != nil {
		in, out := in.Paths, &out.Paths
		*out = make([]ImageSourcePath, len(in))
		for i := range in {
			if err := DeepCopy_v1_ImageSourcePath(in[i], &(*out)[i], c); err != nil {
				return err
			}
		}
	} else {
		out.Paths = nil
	}
	if in.PullSecret != nil {
		in, out := in.PullSecret, &out.PullSecret
		*out = new(api_v1.LocalObjectReference)
		if err := api_v1.DeepCopy_v1_LocalObjectReference(*in, *out, c); err != nil {
			return err
		}
	} else {
		out.PullSecret = nil
	}
	return nil
}
开发者ID:jdnieto,项目名称:origin,代码行数:26,代码来源:deep_copy_generated.go


示例4: DeepCopy_v1_SecretBuildSource

func DeepCopy_v1_SecretBuildSource(in SecretBuildSource, out *SecretBuildSource, c *conversion.Cloner) error {
	if err := api_v1.DeepCopy_v1_LocalObjectReference(in.Secret, &out.Secret, c); err != nil {
		return err
	}
	out.DestinationDir = in.DestinationDir
	return nil
}
开发者ID:jdnieto,项目名称:origin,代码行数:7,代码来源:deep_copy_generated.go


示例5: DeepCopy_v1_DockerBuildStrategy

func DeepCopy_v1_DockerBuildStrategy(in DockerBuildStrategy, out *DockerBuildStrategy, c *conversion.Cloner) error {
	if in.From != nil {
		in, out := in.From, &out.From
		*out = new(api_v1.ObjectReference)
		if err := api_v1.DeepCopy_v1_ObjectReference(*in, *out, c); err != nil {
			return err
		}
	} else {
		out.From = nil
	}
	if in.PullSecret != nil {
		in, out := in.PullSecret, &out.PullSecret
		*out = new(api_v1.LocalObjectReference)
		if err := api_v1.DeepCopy_v1_LocalObjectReference(*in, *out, c); err != nil {
			return err
		}
	} else {
		out.PullSecret = nil
	}
	out.NoCache = in.NoCache
	if in.Env != nil {
		in, out := in.Env, &out.Env
		*out = make([]api_v1.EnvVar, len(in))
		for i := range in {
			if err := api_v1.DeepCopy_v1_EnvVar(in[i], &(*out)[i], c); err != nil {
				return err
			}
		}
	} else {
		out.Env = nil
	}
	out.ForcePull = in.ForcePull
	out.DockerfilePath = in.DockerfilePath
	return nil
}
开发者ID:jdnieto,项目名称:origin,代码行数:35,代码来源:deep_copy_generated.go


示例6: DeepCopy_v1_SourceBuildStrategy

func DeepCopy_v1_SourceBuildStrategy(in SourceBuildStrategy, out *SourceBuildStrategy, c *conversion.Cloner) error {
	if err := api_v1.DeepCopy_v1_ObjectReference(in.From, &out.From, c); err != nil {
		return err
	}
	if in.PullSecret != nil {
		in, out := in.PullSecret, &out.PullSecret
		*out = new(api_v1.LocalObjectReference)
		if err := api_v1.DeepCopy_v1_LocalObjectReference(*in, *out, c); err != nil {
			return err
		}
	} else {
		out.PullSecret = nil
	}
	if in.Env != nil {
		in, out := in.Env, &out.Env
		*out = make([]api_v1.EnvVar, len(in))
		for i := range in {
			if err := api_v1.DeepCopy_v1_EnvVar(in[i], &(*out)[i], c); err != nil {
				return err
			}
		}
	} else {
		out.Env = nil
	}
	out.Scripts = in.Scripts
	if in.Incremental != nil {
		in, out := in.Incremental, &out.Incremental
		*out = new(bool)
		**out = *in
	} else {
		out.Incremental = nil
	}
	out.ForcePull = in.ForcePull
	if in.RuntimeImage != nil {
		in, out := in.RuntimeImage, &out.RuntimeImage
		*out = new(api_v1.ObjectReference)
		if err := api_v1.DeepCopy_v1_ObjectReference(*in, *out, c); err != nil {
			return err
		}
	} else {
		out.RuntimeImage = nil
	}
	if in.RuntimeArtifacts != nil {
		in, out := in.RuntimeArtifacts, &out.RuntimeArtifacts
		*out = make([]ImageSourcePath, len(in))
		for i := range in {
			if err := DeepCopy_v1_ImageSourcePath(in[i], &(*out)[i], c); err != nil {
				return err
			}
		}
	} else {
		out.RuntimeArtifacts = nil
	}
	return nil
}
开发者ID:abhgupta,项目名称:origin,代码行数:55,代码来源:deep_copy_generated.go


示例7: DeepCopy_v1_ImageImportSpec

func DeepCopy_v1_ImageImportSpec(in ImageImportSpec, out *ImageImportSpec, c *conversion.Cloner) error {
	if err := api_v1.DeepCopy_v1_ObjectReference(in.From, &out.From, c); err != nil {
		return err
	}
	if in.To != nil {
		in, out := in.To, &out.To
		*out = new(api_v1.LocalObjectReference)
		if err := api_v1.DeepCopy_v1_LocalObjectReference(*in, *out, c); err != nil {
			return err
		}
	} else {
		out.To = nil
	}
	if err := DeepCopy_v1_TagImportPolicy(in.ImportPolicy, &out.ImportPolicy, c); err != nil {
		return err
	}
	out.IncludeManifest = in.IncludeManifest
	return nil
}
开发者ID:ZenoRewn,项目名称:origin,代码行数:19,代码来源:deep_copy_generated.go


示例8: DeepCopy_v1_BuildOutput

func DeepCopy_v1_BuildOutput(in BuildOutput, out *BuildOutput, c *conversion.Cloner) error {
	if in.To != nil {
		in, out := in.To, &out.To
		*out = new(api_v1.ObjectReference)
		if err := api_v1.DeepCopy_v1_ObjectReference(*in, *out, c); err != nil {
			return err
		}
	} else {
		out.To = nil
	}
	if in.PushSecret != nil {
		in, out := in.PushSecret, &out.PushSecret
		*out = new(api_v1.LocalObjectReference)
		if err := api_v1.DeepCopy_v1_LocalObjectReference(*in, *out, c); err != nil {
			return err
		}
	} else {
		out.PushSecret = nil
	}
	return nil
}
开发者ID:jdnieto,项目名称:origin,代码行数:21,代码来源:deep_copy_generated.go


示例9: DeepCopy_v1_CustomBuildStrategy

func DeepCopy_v1_CustomBuildStrategy(in CustomBuildStrategy, out *CustomBuildStrategy, c *conversion.Cloner) error {
	if err := api_v1.DeepCopy_v1_ObjectReference(in.From, &out.From, c); err != nil {
		return err
	}
	if in.PullSecret != nil {
		in, out := in.PullSecret, &out.PullSecret
		*out = new(api_v1.LocalObjectReference)
		if err := api_v1.DeepCopy_v1_LocalObjectReference(*in, *out, c); err != nil {
			return err
		}
	} else {
		out.PullSecret = nil
	}
	if in.Env != nil {
		in, out := in.Env, &out.Env
		*out = make([]api_v1.EnvVar, len(in))
		for i := range in {
			if err := api_v1.DeepCopy_v1_EnvVar(in[i], &(*out)[i], c); err != nil {
				return err
			}
		}
	} else {
		out.Env = nil
	}
	out.ExposeDockerSocket = in.ExposeDockerSocket
	out.ForcePull = in.ForcePull
	if in.Secrets != nil {
		in, out := in.Secrets, &out.Secrets
		*out = make([]SecretSpec, len(in))
		for i := range in {
			if err := DeepCopy_v1_SecretSpec(in[i], &(*out)[i], c); err != nil {
				return err
			}
		}
	} else {
		out.Secrets = nil
	}
	out.BuildAPIVersion = in.BuildAPIVersion
	return nil
}
开发者ID:jdnieto,项目名称:origin,代码行数:40,代码来源:deep_copy_generated.go


示例10: DeepCopy_v1beta1_ClusterSpec

func DeepCopy_v1beta1_ClusterSpec(in ClusterSpec, out *ClusterSpec, c *conversion.Cloner) error {
	if in.ServerAddressByClientCIDRs != nil {
		in, out := in.ServerAddressByClientCIDRs, &out.ServerAddressByClientCIDRs
		*out = make([]ServerAddressByClientCIDR, len(in))
		for i := range in {
			if err := DeepCopy_v1beta1_ServerAddressByClientCIDR(in[i], &(*out)[i], c); err != nil {
				return err
			}
		}
	} else {
		out.ServerAddressByClientCIDRs = nil
	}
	if in.SecretRef != nil {
		in, out := in.SecretRef, &out.SecretRef
		*out = new(v1.LocalObjectReference)
		if err := v1.DeepCopy_v1_LocalObjectReference(*in, *out, c); err != nil {
			return err
		}
	} else {
		out.SecretRef = nil
	}
	return nil
}
开发者ID:Xmagicer,项目名称:origin,代码行数:23,代码来源:deep_copy_generated.go


示例11: DeepCopy_v1_BuildSource

func DeepCopy_v1_BuildSource(in BuildSource, out *BuildSource, c *conversion.Cloner) error {
	out.Type = in.Type
	if in.Binary != nil {
		in, out := in.Binary, &out.Binary
		*out = new(BinaryBuildSource)
		if err := DeepCopy_v1_BinaryBuildSource(*in, *out, c); err != nil {
			return err
		}
	} else {
		out.Binary = nil
	}
	if in.Dockerfile != nil {
		in, out := in.Dockerfile, &out.Dockerfile
		*out = new(string)
		**out = *in
	} else {
		out.Dockerfile = nil
	}
	if in.Git != nil {
		in, out := in.Git, &out.Git
		*out = new(GitBuildSource)
		if err := DeepCopy_v1_GitBuildSource(*in, *out, c); err != nil {
			return err
		}
	} else {
		out.Git = nil
	}
	if in.Images != nil {
		in, out := in.Images, &out.Images
		*out = make([]ImageSource, len(in))
		for i := range in {
			if err := DeepCopy_v1_ImageSource(in[i], &(*out)[i], c); err != nil {
				return err
			}
		}
	} else {
		out.Images = nil
	}
	out.ContextDir = in.ContextDir
	if in.SourceSecret != nil {
		in, out := in.SourceSecret, &out.SourceSecret
		*out = new(api_v1.LocalObjectReference)
		if err := api_v1.DeepCopy_v1_LocalObjectReference(*in, *out, c); err != nil {
			return err
		}
	} else {
		out.SourceSecret = nil
	}
	if in.Secrets != nil {
		in, out := in.Secrets, &out.Secrets
		*out = make([]SecretBuildSource, len(in))
		for i := range in {
			if err := DeepCopy_v1_SecretBuildSource(in[i], &(*out)[i], c); err != nil {
				return err
			}
		}
	} else {
		out.Secrets = nil
	}
	return nil
}
开发者ID:jdnieto,项目名称:origin,代码行数:61,代码来源:deep_copy_generated.go



注:本文中的k8s/io/kubernetes/pkg/api/v1.DeepCopy_v1_LocalObjectReference函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Golang v1.DeepCopy_v1_ObjectMeta函数代码示例发布时间:2022-05-28
下一篇:
Golang v1.DeepCopy_v1_EnvVar函数代码示例发布时间:2022-05-28
热门推荐
热门话题
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap