hi

package
v0.0.0-...-ac5decb Latest Latest
Warning

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

Go to latest
Published: Apr 10, 2023 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Event_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "hi.Event",
	HandlerType: (*EventServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "AskQuestion",
			Handler:    _Event_AskQuestion_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "hi.proto",
}

Event_ServiceDesc is the grpc.ServiceDesc for Event 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 Greet_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "hi.Greet",
	HandlerType: (*GreetServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "SayHi",
			Handler:    _Greet_SayHi_Handler,
		},
		{
			MethodName: "SayHello",
			Handler:    _Greet_SayHello_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "hi.proto",
}

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

Functions

func RegisterEventServer

func RegisterEventServer(s grpc.ServiceRegistrar, srv EventServer)

func RegisterGreetServer

func RegisterGreetServer(s grpc.ServiceRegistrar, srv GreetServer)

Types

type EventClient

type EventClient interface {
	AskQuestion(ctx context.Context, in *EventReq, opts ...grpc.CallOption) (*EventResp, error)
}

EventClient is the client API for Event 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 NewEventClient

func NewEventClient(cc grpc.ClientConnInterface) EventClient

type EventReq

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

func (*EventReq) Descriptor deprecated

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

Deprecated: Use EventReq.ProtoReflect.Descriptor instead.

func (*EventReq) ProtoMessage

func (*EventReq) ProtoMessage()

func (*EventReq) ProtoReflect

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

func (*EventReq) Reset

func (x *EventReq) Reset()

func (*EventReq) String

func (x *EventReq) String() string

type EventResp

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

func (*EventResp) Descriptor deprecated

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

Deprecated: Use EventResp.ProtoReflect.Descriptor instead.

func (*EventResp) ProtoMessage

func (*EventResp) ProtoMessage()

func (*EventResp) ProtoReflect

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

func (*EventResp) Reset

func (x *EventResp) Reset()

func (*EventResp) String

func (x *EventResp) String() string

type EventServer

type EventServer interface {
	AskQuestion(context.Context, *EventReq) (*EventResp, error)
	// contains filtered or unexported methods
}

EventServer is the server API for Event service. All implementations must embed UnimplementedEventServer for forward compatibility

type GreetClient

type GreetClient interface {
	SayHi(ctx context.Context, in *HiReq, opts ...grpc.CallOption) (*HiResp, error)
	SayHello(ctx context.Context, in *HelloReq, opts ...grpc.CallOption) (*HelloResp, error)
}

GreetClient is the client API for Greet 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 NewGreetClient

func NewGreetClient(cc grpc.ClientConnInterface) GreetClient

type GreetServer

type GreetServer interface {
	SayHi(context.Context, *HiReq) (*HiResp, error)
	SayHello(context.Context, *HelloReq) (*HelloResp, error)
	// contains filtered or unexported methods
}

GreetServer is the server API for Greet service. All implementations must embed UnimplementedGreetServer for forward compatibility

type HelloReq

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

func (*HelloReq) Descriptor deprecated

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

Deprecated: Use HelloReq.ProtoReflect.Descriptor instead.

func (*HelloReq) GetIn

func (x *HelloReq) GetIn() 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 {
	Msg string `protobuf:"bytes,1,opt,name=msg,proto3" json:"msg,omitempty"`
	// contains filtered or unexported fields
}

func (*HelloResp) Descriptor deprecated

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

Deprecated: Use HelloResp.ProtoReflect.Descriptor instead.

func (*HelloResp) GetMsg

func (x *HelloResp) GetMsg() 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 HiReq

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

func (*HiReq) Descriptor deprecated

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

Deprecated: Use HiReq.ProtoReflect.Descriptor instead.

func (*HiReq) GetIn

func (x *HiReq) GetIn() string

func (*HiReq) ProtoMessage

func (*HiReq) ProtoMessage()

func (*HiReq) ProtoReflect

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

func (*HiReq) Reset

func (x *HiReq) Reset()

func (*HiReq) String

func (x *HiReq) String() string

type HiResp

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

func (*HiResp) Descriptor deprecated

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

Deprecated: Use HiResp.ProtoReflect.Descriptor instead.

func (*HiResp) GetMsg

func (x *HiResp) GetMsg() string

func (*HiResp) ProtoMessage

func (*HiResp) ProtoMessage()

func (*HiResp) ProtoReflect

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

func (*HiResp) Reset

func (x *HiResp) Reset()

func (*HiResp) String

func (x *HiResp) String() string

type UnimplementedEventServer

type UnimplementedEventServer struct {
}

UnimplementedEventServer must be embedded to have forward compatible implementations.

func (UnimplementedEventServer) AskQuestion

type UnimplementedGreetServer

type UnimplementedGreetServer struct {
}

UnimplementedGreetServer must be embedded to have forward compatible implementations.

func (UnimplementedGreetServer) SayHello

func (UnimplementedGreetServer) SayHi

type UnsafeEventServer

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

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

type UnsafeGreetServer

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

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

Jump to

Keyboard shortcuts

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