hello

package
v0.0.9 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const (
	HelloService_SayHello_FullMethodName           = "/hello.HelloService/SayHello"
	HelloService_SayManyHellos_FullMethodName      = "/hello.HelloService/SayManyHellos"
	HelloService_SayHelloToEveryone_FullMethodName = "/hello.HelloService/SayHelloToEveryone"
	HelloService_SayHelloContinuous_FullMethodName = "/hello.HelloService/SayHelloContinuous"
)

Variables

View Source
var File_proto_hello_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,
		},
	},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "SayManyHellos",
			Handler:       _HelloService_SayManyHellos_Handler,
			ServerStreams: true,
		},
		{
			StreamName:    "SayHelloToEveryone",
			Handler:       _HelloService_SayHelloToEveryone_Handler,
			ClientStreams: true,
		},
		{
			StreamName:    "SayHelloContinuous",
			Handler:       _HelloService_SayHelloContinuous_Handler,
			ServerStreams: true,
			ClientStreams: true,
		},
	},
	Metadata: "proto/hello/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 HelloRequest

type HelloRequest struct {
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Age  uint32 `protobuf:"varint,16,opt,name=age,proto3" json:"age,omitempty"`
	// contains filtered or unexported fields
}

func (*HelloRequest) Descriptor deprecated

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

Deprecated: Use HelloRequest.ProtoReflect.Descriptor instead.

func (*HelloRequest) GetAge

func (x *HelloRequest) GetAge() uint32

func (*HelloRequest) GetName

func (x *HelloRequest) GetName() string

func (*HelloRequest) ProtoMessage

func (*HelloRequest) ProtoMessage()

func (*HelloRequest) ProtoReflect

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

func (*HelloRequest) Reset

func (x *HelloRequest) Reset()

func (*HelloRequest) String

func (x *HelloRequest) String() string

type HelloResponse

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

func (*HelloResponse) Descriptor deprecated

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

Deprecated: Use HelloResponse.ProtoReflect.Descriptor instead.

func (*HelloResponse) GetGreet

func (x *HelloResponse) GetGreet() string

func (*HelloResponse) ProtoMessage

func (*HelloResponse) ProtoMessage()

func (*HelloResponse) ProtoReflect

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

func (*HelloResponse) Reset

func (x *HelloResponse) Reset()

func (*HelloResponse) String

func (x *HelloResponse) String() string

type HelloServiceClient

type HelloServiceClient interface {
	SayHello(ctx context.Context, in *HelloRequest, opts ...grpc.CallOption) (*HelloResponse, error)
	SayManyHellos(ctx context.Context, in *HelloRequest, opts ...grpc.CallOption) (HelloService_SayManyHellosClient, error)
	SayHelloToEveryone(ctx context.Context, opts ...grpc.CallOption) (HelloService_SayHelloToEveryoneClient, error)
	SayHelloContinuous(ctx context.Context, opts ...grpc.CallOption) (HelloService_SayHelloContinuousClient, 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 {
	SayHello(context.Context, *HelloRequest) (*HelloResponse, error)
	SayManyHellos(*HelloRequest, HelloService_SayManyHellosServer) error
	SayHelloToEveryone(HelloService_SayHelloToEveryoneServer) error
	SayHelloContinuous(HelloService_SayHelloContinuousServer) error
	// contains filtered or unexported methods
}

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

type HelloService_SayHelloContinuousClient added in v0.0.5

type HelloService_SayHelloContinuousClient interface {
	Send(*HelloRequest) error
	Recv() (*HelloResponse, error)
	grpc.ClientStream
}

type HelloService_SayHelloContinuousServer added in v0.0.5

type HelloService_SayHelloContinuousServer interface {
	Send(*HelloResponse) error
	Recv() (*HelloRequest, error)
	grpc.ServerStream
}

type HelloService_SayHelloToEveryoneClient added in v0.0.4

type HelloService_SayHelloToEveryoneClient interface {
	Send(*HelloRequest) error
	CloseAndRecv() (*HelloResponse, error)
	grpc.ClientStream
}

type HelloService_SayHelloToEveryoneServer added in v0.0.4

type HelloService_SayHelloToEveryoneServer interface {
	SendAndClose(*HelloResponse) error
	Recv() (*HelloRequest, error)
	grpc.ServerStream
}

type HelloService_SayManyHellosClient added in v0.0.3

type HelloService_SayManyHellosClient interface {
	Recv() (*HelloResponse, error)
	grpc.ClientStream
}

type HelloService_SayManyHellosServer added in v0.0.3

type HelloService_SayManyHellosServer interface {
	Send(*HelloResponse) error
	grpc.ServerStream
}

type UnimplementedHelloServiceServer

type UnimplementedHelloServiceServer struct {
}

UnimplementedHelloServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedHelloServiceServer) SayHello

func (UnimplementedHelloServiceServer) SayHelloContinuous added in v0.0.5

func (UnimplementedHelloServiceServer) SayHelloToEveryone added in v0.0.4

func (UnimplementedHelloServiceServer) SayManyHellos added in v0.0.3

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