本文整理汇总了Golang中k8s/io/kubernetes/pkg/client/testing/core.NewRootGetAction函数的典型用法代码示例。如果您正苦于以下问题:Golang NewRootGetAction函数的具体用法?Golang NewRootGetAction怎么用?Golang NewRootGetAction使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了NewRootGetAction函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Golang代码示例。
示例1: Get
func (c *FakeProjects) Get(name string) (result *api.Project, err error) {
obj, err := c.Fake.
Invokes(core.NewRootGetAction(projectsResource, name), &api.Project{})
if obj == nil {
return nil, err
}
return obj.(*api.Project), err
}
示例2: Get
func (c *FakeThirdPartyResources) Get(name string) (result *extensions.ThirdPartyResource, err error) {
obj, err := c.Fake.
Invokes(core.NewRootGetAction(thirdpartyresourcesResource, name), &extensions.ThirdPartyResource{})
if obj == nil {
return nil, err
}
return obj.(*extensions.ThirdPartyResource), err
}
示例3: Get
func (c *FakeClusters) Get(name string) (result *federation.Cluster, err error) {
obj, err := c.Fake.
Invokes(core.NewRootGetAction(clustersResource, name), &federation.Cluster{})
if obj == nil {
return nil, err
}
return obj.(*federation.Cluster), err
}
示例4: Get
func (c *FakePersistentVolumes) Get(name string, options meta_v1.GetOptions) (result *v1.PersistentVolume, err error) {
obj, err := c.Fake.
Invokes(core.NewRootGetAction(persistentvolumesResource, name), &v1.PersistentVolume{})
if obj == nil {
return nil, err
}
return obj.(*v1.PersistentVolume), err
}
示例5: Get
func (c *FakeOAuthClient) Get(name string) (*oauthapi.OAuthClient, error) {
obj, err := c.Fake.Invokes(core.NewRootGetAction(oAuthClientsResource, name), &oauthapi.OAuthClient{})
if obj == nil {
return nil, err
}
return obj.(*oauthapi.OAuthClient), err
}
示例6: Get
func (c *FakeNodes) Get(name string) (result *api.Node, err error) {
obj, err := c.Fake.
Invokes(core.NewRootGetAction("nodes", name), &api.Node{})
if obj == nil {
return nil, err
}
return obj.(*api.Node), err
}
示例7: Get
func (c *FakeStorageClasses) Get(name string) (result *storage.StorageClass, err error) {
obj, err := c.Fake.
Invokes(core.NewRootGetAction(storageclassesResource, name), &storage.StorageClass{})
if obj == nil {
return nil, err
}
return obj.(*storage.StorageClass), err
}
示例8: Get
func (c *FakeStorageClasses) Get(name string, options meta_v1.GetOptions) (result *v1beta1.StorageClass, err error) {
obj, err := c.Fake.
Invokes(core.NewRootGetAction(storageclassesResource, name), &v1beta1.StorageClass{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.StorageClass), err
}
示例9: Get
func (c *FakeComponentStatus) Get(name string) (result *api.ComponentStatus, err error) {
obj, err := c.Fake.
Invokes(core.NewRootGetAction("componentStatus", name), &api.ComponentStatus{})
if obj == nil {
return nil, err
}
return obj.(*api.ComponentStatus), err
}
示例10: Get
func (c *FakeAPIServices) Get(name string) (result *v1alpha1.APIService, err error) {
obj, err := c.Fake.
Invokes(core.NewRootGetAction(apiservicesResource, name), &v1alpha1.APIService{})
if obj == nil {
return nil, err
}
return obj.(*v1alpha1.APIService), err
}
示例11: Get
// Get returns information about a particular image and error if one occurs.
func (c *FakeOAuthAccessTokens) Get(name string) (*oauthapi.OAuthAccessToken, error) {
obj, err := c.Fake.Invokes(core.NewRootGetAction(oAuthAccessTokensResource, name), &oauthapi.OAuthAccessToken{})
if obj == nil {
return nil, err
}
return obj.(*oauthapi.OAuthAccessToken), err
}
示例12: Get
func (c *FakeUserIdentityMappings) Get(name string) (*userapi.UserIdentityMapping, error) {
obj, err := c.Fake.Invokes(core.NewRootGetAction(userIdentityMappingsResource, name), &userapi.UserIdentityMapping{})
if obj == nil {
return nil, err
}
return obj.(*userapi.UserIdentityMapping), err
}
示例13: Get
func (c *FakeIdentities) Get(name string) (*userapi.Identity, error) {
obj, err := c.Fake.Invokes(core.NewRootGetAction(identitiesResource, name), &userapi.Identity{})
if obj == nil {
return nil, err
}
return obj.(*userapi.Identity), err
}
示例14: Get
func (c *FakeClusterResourceQuotas) Get(name string) (*quotaapi.ClusterResourceQuota, error) {
obj, err := c.Fake.Invokes(core.NewRootGetAction(clusteResourceQuotasResource, name), "aapi.ClusterResourceQuota{})
if obj == nil {
return nil, err
}
return obj.(*quotaapi.ClusterResourceQuota), err
}
示例15: Get
func (c *FakeAPIServices) Get(name string, options v1.GetOptions) (result *apiregistration.APIService, err error) {
obj, err := c.Fake.
Invokes(core.NewRootGetAction(apiservicesResource, name), &apiregistration.APIService{})
if obj == nil {
return nil, err
}
return obj.(*apiregistration.APIService), err
}