Documentation ¶
Index ¶
- Variables
- func RegisterHelloWorldServer(s grpc.ServiceRegistrar, srv HelloWorldServer)
- type Hello
- func (*Hello) Descriptor() ([]byte, []int)deprecated
- func (x *Hello) GetName() string
- func (this *Hello) MarshalPacket() ([]byte, error)
- func (*Hello) ProtoMessage()
- func (x *Hello) ProtoReflect() protoreflect.Message
- func (x *Hello) Reset()
- func (x *Hello) String() string
- func (this *Hello) UnmarshalPacket([]byte) error
- type HelloWorldClient
- type HelloWorldServer
- type HelloWorld_StreamClient
- type HelloWorld_StreamServer
- type UnimplementedHelloWorldServer
- type UnsafeHelloWorldServer
- type World
- func (*World) Descriptor() ([]byte, []int)deprecated
- func (x *World) GetMessage() string
- func (this *World) MarshalPacket() ([]byte, error)
- func (*World) ProtoMessage()
- func (x *World) ProtoReflect() protoreflect.Message
- func (x *World) Reset()
- func (x *World) String() string
- func (this *World) UnmarshalPacket([]byte) error
Constants ¶
This section is empty.
Variables ¶
var File_hello_proto protoreflect.FileDescriptor
var HelloWorld_ServiceDesc = grpc.ServiceDesc{ ServiceName: "proto.HelloWorld", HandlerType: (*HelloWorldServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Call", Handler: _HelloWorld_Call_Handler, }, }, Streams: []grpc.StreamDesc{ { StreamName: "Stream", Handler: _HelloWorld_Stream_Handler, ServerStreams: true, ClientStreams: true, }, }, Metadata: "hello.proto", }
HelloWorld_ServiceDesc is the grpc.ServiceDesc for HelloWorld service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterHelloWorldServer ¶
func RegisterHelloWorldServer(s grpc.ServiceRegistrar, srv HelloWorldServer)
Types ¶
type Hello ¶
type Hello struct { Name string `protobuf:"bytes,1,opt,name=Name,proto3" json:"Name,omitempty"` // contains filtered or unexported fields }
func (*Hello) Descriptor
deprecated
func (*Hello) MarshalPacket ¶
func (*Hello) ProtoMessage ¶
func (*Hello) ProtoMessage()
func (*Hello) ProtoReflect ¶
func (x *Hello) ProtoReflect() protoreflect.Message
func (*Hello) UnmarshalPacket ¶
type HelloWorldClient ¶
type HelloWorldClient interface { Call(ctx context.Context, in *Hello, opts ...grpc.CallOption) (*World, error) Stream(ctx context.Context, opts ...grpc.CallOption) (HelloWorld_StreamClient, error) }
HelloWorldClient is the client API for HelloWorld 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 NewHelloWorldClient ¶
func NewHelloWorldClient(cc grpc.ClientConnInterface) HelloWorldClient
type HelloWorldServer ¶
type HelloWorldServer interface { Call(context.Context, *Hello) (*World, error) Stream(HelloWorld_StreamServer) error // contains filtered or unexported methods }
HelloWorldServer is the server API for HelloWorld service. All implementations must embed UnimplementedHelloWorldServer for forward compatibility
type HelloWorld_StreamClient ¶
type HelloWorld_StreamServer ¶
type UnimplementedHelloWorldServer ¶
type UnimplementedHelloWorldServer struct { }
UnimplementedHelloWorldServer must be embedded to have forward compatible implementations.
func (UnimplementedHelloWorldServer) Stream ¶
func (UnimplementedHelloWorldServer) Stream(HelloWorld_StreamServer) error
type UnsafeHelloWorldServer ¶
type UnsafeHelloWorldServer interface {
// contains filtered or unexported methods
}
UnsafeHelloWorldServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to HelloWorldServer will result in compilation errors.
type World ¶
type World struct { Message string `protobuf:"bytes,1,opt,name=Message,proto3" json:"Message,omitempty"` // contains filtered or unexported fields }
func (*World) Descriptor
deprecated
func (*World) GetMessage ¶
func (*World) MarshalPacket ¶
func (*World) ProtoMessage ¶
func (*World) ProtoMessage()
func (*World) ProtoReflect ¶
func (x *World) ProtoReflect() protoreflect.Message