本文整理汇总了Golang中k8s/io/kubernetes/pkg/client/testing/core.CreateActionImpl类的典型用法代码示例。如果您正苦于以下问题:Golang CreateActionImpl类的具体用法?Golang CreateActionImpl怎么用?Golang CreateActionImpl使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了CreateActionImpl类的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Golang代码示例。
示例1: Rollback
func (c *FakeDeployments) Rollback(deploymentRollback *extensions.DeploymentRollback) error {
action := core.CreateActionImpl{}
action.Verb = "create"
action.Resource = deploymentsResource
action.Subresource = "rollback"
action.Object = deploymentRollback
_, err := c.Fake.Invokes(action, deploymentRollback)
return err
}
开发者ID:Clarifai,项目名称:kubernetes,代码行数:10,代码来源:fake_deployment_expansion.go
示例2: Bind
func (c *FakePods) Bind(binding *api.Binding) error {
action := core.CreateActionImpl{}
action.Verb = "create"
action.Resource = "pods"
action.Subresource = "bindings"
action.Object = binding
_, err := c.Fake.Invokes(action, binding)
return err
}
开发者ID:RomainVabre,项目名称:origin,代码行数:10,代码来源:fake_pod_expansion.go
示例3: Evict
func (c *FakePods) Evict(eviction *policy.Eviction) error {
action := core.CreateActionImpl{}
action.Verb = "create"
action.Resource = podsResource
action.Subresource = "eviction"
action.Object = eviction
_, err := c.Fake.Invokes(action, eviction)
return err
}
开发者ID:eljefedelrodeodeljefe,项目名称:kubernetes,代码行数:10,代码来源:fake_pod_expansion.go
示例4: Finalize
func (c *FakeNamespaces) Finalize(namespace *api.Namespace) (*api.Namespace, error) {
action := core.CreateActionImpl{}
action.Verb = "create"
action.Resource = "namespaces"
action.Subresource = "finalize"
action.Object = namespace
obj, err := c.Fake.Invokes(action, namespace)
if obj == nil {
return nil, err
}
return obj.(*api.Namespace), err
}
开发者ID:CNDonny,项目名称:scope,代码行数:14,代码来源:fake_namespace_expansion.go
注:本文中的k8s/io/kubernetes/pkg/client/testing/core.CreateActionImpl类示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论