proto

package
v0.0.0-...-cdc24ad Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 30, 2023 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Cache_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "cache.cache",
	HandlerType: (*CacheServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Item",
			Handler:    _Cache_Item_Handler,
		},
		{
			MethodName: "CreateItem",
			Handler:    _Cache_CreateItem_Handler,
		},
		{
			MethodName: "DeleteItem",
			Handler:    _Cache_DeleteItem_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "proto/cache.proto",
}

Cache_ServiceDesc is the grpc.ServiceDesc for Cache service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var File_proto_cache_proto protoreflect.FileDescriptor

Functions

func RegisterCacheServer

func RegisterCacheServer(s grpc.ServiceRegistrar, srv CacheServer)

Types

type CacheClient

type CacheClient interface {
	Item(ctx context.Context, in *ItemRequest, opts ...grpc.CallOption) (*ItemResponse, error)
	CreateItem(ctx context.Context, in *CreateItemRequest, opts ...grpc.CallOption) (*ItemResponse, error)
	DeleteItem(ctx context.Context, in *DeleteItemRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
}

CacheClient is the client API for Cache service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewCacheClient

func NewCacheClient(cc grpc.ClientConnInterface) CacheClient

type CacheServer

type CacheServer interface {
	Item(context.Context, *ItemRequest) (*ItemResponse, error)
	CreateItem(context.Context, *CreateItemRequest) (*ItemResponse, error)
	DeleteItem(context.Context, *DeleteItemRequest) (*emptypb.Empty, error)
	// contains filtered or unexported methods
}

CacheServer is the server API for Cache service. All implementations must embed UnimplementedCacheServer for forward compatibility

type CreateItemRequest

type CreateItemRequest struct {
	Domain string `protobuf:"bytes,1,opt,name=domain,proto3" json:"domain,omitempty"`
	Name   string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	Value  []byte `protobuf:"bytes,3,opt,name=value,proto3" json:"value,omitempty"`
	// contains filtered or unexported fields
}

func (*CreateItemRequest) Descriptor deprecated

func (*CreateItemRequest) Descriptor() ([]byte, []int)

Deprecated: Use CreateItemRequest.ProtoReflect.Descriptor instead.

func (*CreateItemRequest) GetDomain

func (x *CreateItemRequest) GetDomain() string

func (*CreateItemRequest) GetName

func (x *CreateItemRequest) GetName() string

func (*CreateItemRequest) GetValue

func (x *CreateItemRequest) GetValue() []byte

func (*CreateItemRequest) ProtoMessage

func (*CreateItemRequest) ProtoMessage()

func (*CreateItemRequest) ProtoReflect

func (x *CreateItemRequest) ProtoReflect() protoreflect.Message

func (*CreateItemRequest) Reset

func (x *CreateItemRequest) Reset()

func (*CreateItemRequest) String

func (x *CreateItemRequest) String() string

type DeleteItemRequest

type DeleteItemRequest struct {
	Domain string `protobuf:"bytes,1,opt,name=domain,proto3" json:"domain,omitempty"`
	Name   string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	// contains filtered or unexported fields
}

func (*DeleteItemRequest) Descriptor deprecated

func (*DeleteItemRequest) Descriptor() ([]byte, []int)

Deprecated: Use DeleteItemRequest.ProtoReflect.Descriptor instead.

func (*DeleteItemRequest) GetDomain

func (x *DeleteItemRequest) GetDomain() string

func (*DeleteItemRequest) GetName

func (x *DeleteItemRequest) GetName() string

func (*DeleteItemRequest) ProtoMessage

func (*DeleteItemRequest) ProtoMessage()

func (*DeleteItemRequest) ProtoReflect

func (x *DeleteItemRequest) ProtoReflect() protoreflect.Message

func (*DeleteItemRequest) Reset

func (x *DeleteItemRequest) Reset()

func (*DeleteItemRequest) String

func (x *DeleteItemRequest) String() string

type ItemRequest

type ItemRequest struct {
	Domain string `protobuf:"bytes,1,opt,name=domain,proto3" json:"domain,omitempty"`
	Name   string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	// contains filtered or unexported fields
}

func (*ItemRequest) Descriptor deprecated

func (*ItemRequest) Descriptor() ([]byte, []int)

Deprecated: Use ItemRequest.ProtoReflect.Descriptor instead.

func (*ItemRequest) GetDomain

func (x *ItemRequest) GetDomain() string

func (*ItemRequest) GetName

func (x *ItemRequest) GetName() string

func (*ItemRequest) ProtoMessage

func (*ItemRequest) ProtoMessage()

func (*ItemRequest) ProtoReflect

func (x *ItemRequest) ProtoReflect() protoreflect.Message

func (*ItemRequest) Reset

func (x *ItemRequest) Reset()

func (*ItemRequest) String

func (x *ItemRequest) String() string

type ItemResponse

type ItemResponse struct {
	Value []byte `protobuf:"bytes,1,opt,name=value,proto3" json:"value,omitempty"`
	// contains filtered or unexported fields
}

func (*ItemResponse) Descriptor deprecated

func (*ItemResponse) Descriptor() ([]byte, []int)

Deprecated: Use ItemResponse.ProtoReflect.Descriptor instead.

func (*ItemResponse) GetValue

func (x *ItemResponse) GetValue() []byte

func (*ItemResponse) ProtoMessage

func (*ItemResponse) ProtoMessage()

func (*ItemResponse) ProtoReflect

func (x *ItemResponse) ProtoReflect() protoreflect.Message

func (*ItemResponse) Reset

func (x *ItemResponse) Reset()

func (*ItemResponse) String

func (x *ItemResponse) String() string

type UnimplementedCacheServer

type UnimplementedCacheServer struct {
}

UnimplementedCacheServer must be embedded to have forward compatible implementations.

func (UnimplementedCacheServer) CreateItem

func (UnimplementedCacheServer) DeleteItem

func (UnimplementedCacheServer) Item

type UnsafeCacheServer

type UnsafeCacheServer interface {
	// contains filtered or unexported methods
}

UnsafeCacheServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to CacheServer will result in compilation errors.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL