hello

package
v0.0.0-...-3494f84 Latest Latest
Warning

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

Go to latest
Published: Nov 22, 2021 License: MIT Imports: 8 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_hello_proto protoreflect.FileDescriptor
View Source
var HelloService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "hello.HelloService",
	HandlerType: (*HelloServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "SayHello",
			Handler:    _HelloService_SayHello_Handler,
		},
		{
			MethodName: "SayHelloStrict",
			Handler:    _HelloService_SayHelloStrict_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "hello.proto",
}

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

Functions

func RegisterHelloServiceServer

func RegisterHelloServiceServer(s grpc.ServiceRegistrar, srv HelloServiceServer)

Types

type HelloReq

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

func (*HelloReq) Descriptor deprecated

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

Deprecated: Use HelloReq.ProtoReflect.Descriptor instead.

func (*HelloReq) GetName

func (x *HelloReq) GetName() string

func (*HelloReq) ProtoMessage

func (*HelloReq) ProtoMessage()

func (*HelloReq) ProtoReflect

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

func (*HelloReq) Reset

func (x *HelloReq) Reset()

func (*HelloReq) String

func (x *HelloReq) String() string

type HelloResp

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

func (*HelloResp) Descriptor deprecated

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

Deprecated: Use HelloResp.ProtoReflect.Descriptor instead.

func (*HelloResp) GetResult

func (x *HelloResp) GetResult() string

func (*HelloResp) ProtoMessage

func (*HelloResp) ProtoMessage()

func (*HelloResp) ProtoReflect

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

func (*HelloResp) Reset

func (x *HelloResp) Reset()

func (*HelloResp) String

func (x *HelloResp) String() string

type HelloServiceClient

type HelloServiceClient interface {
	// This thing just says Hello to anyone
	// SayHello('Euler') -> Hello, Euler!
	SayHello(ctx context.Context, in *HelloReq, opts ...grpc.CallOption) (*HelloResp, error)
	// Strict Version responds only to requests which have `Name` length
	// less than 10 characters
	SayHelloStrict(ctx context.Context, in *HelloReq, opts ...grpc.CallOption) (*HelloResp, error)
}

HelloServiceClient is the client API for HelloService 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.

type HelloServiceServer

type HelloServiceServer interface {
	// This thing just says Hello to anyone
	// SayHello('Euler') -> Hello, Euler!
	SayHello(context.Context, *HelloReq) (*HelloResp, error)
	// Strict Version responds only to requests which have `Name` length
	// less than 10 characters
	SayHelloStrict(context.Context, *HelloReq) (*HelloResp, error)
	// contains filtered or unexported methods
}

HelloServiceServer is the server API for HelloService service. All implementations must embed UnimplementedHelloServiceServer for forward compatibility

type UnimplementedHelloServiceServer

type UnimplementedHelloServiceServer struct {
}

UnimplementedHelloServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedHelloServiceServer) SayHello

func (UnimplementedHelloServiceServer) SayHelloStrict

type UnsafeHelloServiceServer

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

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

Jump to

Keyboard shortcuts

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