pb

package
v0.0.0-...-e53b883 Latest Latest
Warning

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

Go to latest
Published: May 17, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Serve_Put_FullMethodName = "/serve.Serve/Put"
	Serve_Get_FullMethodName = "/serve.Serve/Get"
)

Variables

View Source
var File_serve_proto protoreflect.FileDescriptor
View Source
var Serve_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "serve.Serve",
	HandlerType: (*ServeServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Put",
			Handler:    _Serve_Put_Handler,
		},
		{
			MethodName: "Get",
			Handler:    _Serve_Get_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "serve.proto",
}

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

Functions

func RegisterServeServer

func RegisterServeServer(s grpc.ServiceRegistrar, srv ServeServer)

Types

type Key

type Key struct {
	Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	// contains filtered or unexported fields
}

func (*Key) Descriptor deprecated

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

Deprecated: Use Key.ProtoReflect.Descriptor instead.

func (*Key) GetKey

func (x *Key) GetKey() string

func (*Key) ProtoMessage

func (*Key) ProtoMessage()

func (*Key) ProtoReflect

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

func (*Key) Reset

func (x *Key) Reset()

func (*Key) String

func (x *Key) String() string

type Nil

type Nil struct {
	// contains filtered or unexported fields
}

func (*Nil) Descriptor deprecated

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

Deprecated: Use Nil.ProtoReflect.Descriptor instead.

func (*Nil) ProtoMessage

func (*Nil) ProtoMessage()

func (*Nil) ProtoReflect

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

func (*Nil) Reset

func (x *Nil) Reset()

func (*Nil) String

func (x *Nil) String() string

type Pair

type Pair struct {
	Key   string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	Value string `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
	// contains filtered or unexported fields
}

func (*Pair) Descriptor deprecated

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

Deprecated: Use Pair.ProtoReflect.Descriptor instead.

func (*Pair) GetKey

func (x *Pair) GetKey() string

func (*Pair) GetValue

func (x *Pair) GetValue() string

func (*Pair) ProtoMessage

func (*Pair) ProtoMessage()

func (*Pair) ProtoReflect

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

func (*Pair) Reset

func (x *Pair) Reset()

func (*Pair) String

func (x *Pair) String() string

type ServeClient

type ServeClient interface {
	Put(ctx context.Context, in *Pair, opts ...grpc.CallOption) (*Nil, error)
	Get(ctx context.Context, in *Key, opts ...grpc.CallOption) (*Value, error)
}

ServeClient is the client API for Serve 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 NewServeClient

func NewServeClient(cc grpc.ClientConnInterface) ServeClient

type ServeServer

type ServeServer interface {
	Put(context.Context, *Pair) (*Nil, error)
	Get(context.Context, *Key) (*Value, error)
	// contains filtered or unexported methods
}

ServeServer is the server API for Serve service. All implementations must embed UnimplementedServeServer for forward compatibility

type UnimplementedServeServer

type UnimplementedServeServer struct {
}

UnimplementedServeServer must be embedded to have forward compatible implementations.

func (UnimplementedServeServer) Get

func (UnimplementedServeServer) Put

type UnsafeServeServer

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

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

type Value

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

func (*Value) Descriptor deprecated

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

Deprecated: Use Value.ProtoReflect.Descriptor instead.

func (*Value) GetValue

func (x *Value) GetValue() string

func (*Value) ProtoMessage

func (*Value) ProtoMessage()

func (*Value) ProtoReflect

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

func (*Value) Reset

func (x *Value) Reset()

func (*Value) String

func (x *Value) String() string

Jump to

Keyboard shortcuts

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