Documentation ¶
Index ¶
- Constants
- Variables
- func IfNotNilPanic(err error)
- func RegisterGreetingNRServer(register natsrpc.ServiceRegistrar, s GreetingNRServer, ...) (natsrpc.ServiceInterface, error)
- func RegisterGreetingToAllNRServer(register natsrpc.ServiceRegistrar, s GreetingToAllNRServer, ...) (natsrpc.ServiceInterface, error)
- type Empty
- type GreetingNRClient
- type GreetingNRServer
- type GreetingToAllNRClient
- type GreetingToAllNRServer
- type HelloReply
- type HelloRequest
Constants ¶
View Source
const (
GreetingToAll_NRServiceName = "natsrpc.example.GreetingToAll"
)
View Source
const (
Greeting_NRServiceName = "natsrpc.example.Greeting"
)
Variables ¶
View Source
var File_example_proto protoreflect.FileDescriptor
View Source
var GreetingToAll_NRServiceDesc = natsrpc.ServiceDesc{ ServiceName: GreetingToAll_NRServiceName, Methods: []natsrpc.MethodDesc{ { MethodName: "HelloToAll", Handler: _GreetingToAll_HelloToAll_NRHandler, RequestType: reflect.TypeOf(HelloRequest{}), IsPublish: true, }, }, Metadata: "example.proto", }
View Source
var Greeting_NRServiceDesc = natsrpc.ServiceDesc{ ServiceName: Greeting_NRServiceName, Methods: []natsrpc.MethodDesc{ { MethodName: "Hello", Handler: _Greeting_Hello_NRHandler, RequestType: reflect.TypeOf(HelloRequest{}), IsPublish: false, }, }, Metadata: "example.proto", }
Functions ¶
func IfNotNilPanic ¶
func IfNotNilPanic(err error)
func RegisterGreetingNRServer ¶
func RegisterGreetingNRServer(register natsrpc.ServiceRegistrar, s GreetingNRServer, opts ...natsrpc.ServiceOption) (natsrpc.ServiceInterface, error)
func RegisterGreetingToAllNRServer ¶
func RegisterGreetingToAllNRServer(register natsrpc.ServiceRegistrar, s GreetingToAllNRServer, opts ...natsrpc.ServiceOption) (natsrpc.ServiceInterface, error)
Types ¶
type Empty ¶
type Empty struct {
// contains filtered or unexported fields
}
func (*Empty) Descriptor
deprecated
func (*Empty) ProtoMessage ¶
func (*Empty) ProtoMessage()
func (*Empty) ProtoReflect ¶
func (x *Empty) ProtoReflect() protoreflect.Message
type GreetingNRClient ¶
type GreetingNRClient interface {
Hello(ctx context.Context, req *HelloRequest, opt ...natsrpc.CallOption) (*HelloReply, error)
}
func NewGreetingNRClient ¶
func NewGreetingNRClient(c natsrpc.ClientInterface) GreetingNRClient
NewGreetingNRClient
type GreetingNRServer ¶
type GreetingNRServer interface {
Hello(ctx context.Context, req *HelloRequest) (*HelloReply, error)
}
type GreetingToAllNRClient ¶
type GreetingToAllNRClient interface {
HelloToAll(ctx context.Context, notify *HelloRequest, opt ...natsrpc.CallOption) error
}
func NewGreetingToAllNRClient ¶
func NewGreetingToAllNRClient(c natsrpc.ClientInterface) GreetingToAllNRClient
NewGreetingToAllNRClient
type GreetingToAllNRServer ¶
type GreetingToAllNRServer interface {
HelloToAll(ctx context.Context, req *HelloRequest) (*Empty, error)
}
type HelloReply ¶
type HelloReply struct { Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"` // contains filtered or unexported fields }
func (*HelloReply) Descriptor
deprecated
func (*HelloReply) Descriptor() ([]byte, []int)
Deprecated: Use HelloReply.ProtoReflect.Descriptor instead.
func (*HelloReply) GetMessage ¶
func (x *HelloReply) GetMessage() string
func (*HelloReply) ProtoMessage ¶
func (*HelloReply) ProtoMessage()
func (*HelloReply) ProtoReflect ¶
func (x *HelloReply) ProtoReflect() protoreflect.Message
func (*HelloReply) Reset ¶
func (x *HelloReply) Reset()
func (*HelloReply) String ¶
func (x *HelloReply) String() string
type HelloRequest ¶
type HelloRequest struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // contains filtered or unexported fields }
func (*HelloRequest) Descriptor
deprecated
func (*HelloRequest) Descriptor() ([]byte, []int)
Deprecated: Use HelloRequest.ProtoReflect.Descriptor instead.
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
Click to show internal directories.
Click to hide internal directories.