41 lines
1.2 KiB
Go
41 lines
1.2 KiB
Go
// Code generated by sdkgen. DO NOT EDIT.
|
|
|
|
//nolint
|
|
package redis
|
|
|
|
import (
|
|
"context"
|
|
|
|
"google.golang.org/grpc"
|
|
|
|
"github.com/yandex-cloud/go-genproto/yandex/cloud/mdb/redis/v1"
|
|
)
|
|
|
|
//revive:disable
|
|
|
|
// ResourcePresetServiceClient is a redis.ResourcePresetServiceClient with
|
|
// lazy GRPC connection initialization.
|
|
type ResourcePresetServiceClient struct {
|
|
getConn func(ctx context.Context) (*grpc.ClientConn, error)
|
|
}
|
|
|
|
var _ redis.ResourcePresetServiceClient = &ResourcePresetServiceClient{}
|
|
|
|
// Get implements redis.ResourcePresetServiceClient
|
|
func (c *ResourcePresetServiceClient) Get(ctx context.Context, in *redis.GetResourcePresetRequest, opts ...grpc.CallOption) (*redis.ResourcePreset, error) {
|
|
conn, err := c.getConn(ctx)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return redis.NewResourcePresetServiceClient(conn).Get(ctx, in, opts...)
|
|
}
|
|
|
|
// List implements redis.ResourcePresetServiceClient
|
|
func (c *ResourcePresetServiceClient) List(ctx context.Context, in *redis.ListResourcePresetsRequest, opts ...grpc.CallOption) (*redis.ListResourcePresetsResponse, error) {
|
|
conn, err := c.getConn(ctx)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return redis.NewResourcePresetServiceClient(conn).List(ctx, in, opts...)
|
|
}
|