Documentation ¶
Index ¶
- Variables
- func RegisterMessengerServer(s grpc.ServiceRegistrar, srv MessengerServer)
- type Confirmation
- func (*Confirmation) Descriptor() ([]byte, []int)deprecated
- func (x *Confirmation) GetMessage() string
- func (x *Confirmation) GetStatus() Confirmation_Status
- func (*Confirmation) ProtoMessage()
- func (x *Confirmation) ProtoReflect() protoreflect.Message
- func (x *Confirmation) Reset()
- func (x *Confirmation) String() string
- type Confirmation_Status
- func (Confirmation_Status) Descriptor() protoreflect.EnumDescriptor
- func (x Confirmation_Status) Enum() *Confirmation_Status
- func (Confirmation_Status) EnumDescriptor() ([]byte, []int)deprecated
- func (x Confirmation_Status) Number() protoreflect.EnumNumber
- func (x Confirmation_Status) String() string
- func (Confirmation_Status) Type() protoreflect.EnumType
- type Message
- func (*Message) Descriptor() ([]byte, []int)deprecated
- func (x *Message) GetAge() int32
- func (x *Message) GetGender() string
- func (x *Message) GetLocation() string
- func (x *Message) GetName() string
- func (x *Message) GetService() string
- func (x *Message) GetVaccineType() string
- func (*Message) ProtoMessage()
- func (x *Message) ProtoReflect() protoreflect.Message
- func (x *Message) Reset()
- func (x *Message) String() string
- type MessengerClient
- type MessengerServer
- type UnimplementedMessengerServer
- type UnsafeMessengerServer
Constants ¶
This section is empty.
Variables ¶
var ( Confirmation_Status_name = map[int32]string{ 0: "Error", 1: "Successful", } Confirmation_Status_value = map[string]int32{ "Error": 0, "Successful": 1, } )
Enum value maps for Confirmation_Status.
var File_message_proto protoreflect.FileDescriptor
var Messenger_ServiceDesc = grpc.ServiceDesc{ ServiceName: "message.Messenger", HandlerType: (*MessengerServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "registerMessage", Handler: _Messenger_RegisterMessage_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "message.proto", }
Messenger_ServiceDesc is the grpc.ServiceDesc for Messenger service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterMessengerServer ¶
func RegisterMessengerServer(s grpc.ServiceRegistrar, srv MessengerServer)
Types ¶
type Confirmation ¶
type Confirmation struct { Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"` Status Confirmation_Status `protobuf:"varint,2,opt,name=status,proto3,enum=message.Confirmation_Status" json:"status,omitempty"` // contains filtered or unexported fields }
func (*Confirmation) Descriptor
deprecated
func (*Confirmation) Descriptor() ([]byte, []int)
Deprecated: Use Confirmation.ProtoReflect.Descriptor instead.
func (*Confirmation) GetMessage ¶
func (x *Confirmation) GetMessage() string
func (*Confirmation) GetStatus ¶
func (x *Confirmation) GetStatus() Confirmation_Status
func (*Confirmation) ProtoMessage ¶
func (*Confirmation) ProtoMessage()
func (*Confirmation) ProtoReflect ¶
func (x *Confirmation) ProtoReflect() protoreflect.Message
func (*Confirmation) Reset ¶
func (x *Confirmation) Reset()
func (*Confirmation) String ¶
func (x *Confirmation) String() string
type Confirmation_Status ¶
type Confirmation_Status int32
const ( Confirmation_Error Confirmation_Status = 0 Confirmation_Successful Confirmation_Status = 1 )
func (Confirmation_Status) Descriptor ¶
func (Confirmation_Status) Descriptor() protoreflect.EnumDescriptor
func (Confirmation_Status) Enum ¶
func (x Confirmation_Status) Enum() *Confirmation_Status
func (Confirmation_Status) EnumDescriptor
deprecated
func (Confirmation_Status) EnumDescriptor() ([]byte, []int)
Deprecated: Use Confirmation_Status.Descriptor instead.
func (Confirmation_Status) Number ¶
func (x Confirmation_Status) Number() protoreflect.EnumNumber
func (Confirmation_Status) String ¶
func (x Confirmation_Status) String() string
func (Confirmation_Status) Type ¶
func (Confirmation_Status) Type() protoreflect.EnumType
type Message ¶
type Message struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Location string `protobuf:"bytes,2,opt,name=location,proto3" json:"location,omitempty"` Gender string `protobuf:"bytes,3,opt,name=gender,proto3" json:"gender,omitempty"` Age int32 `protobuf:"varint,4,opt,name=age,proto3" json:"age,omitempty"` VaccineType string `protobuf:"bytes,5,opt,name=vaccine_type,json=vaccineType,proto3" json:"vaccine_type,omitempty"` Service string `protobuf:"bytes,6,opt,name=service,proto3" json:"service,omitempty"` // contains filtered or unexported fields }
func (*Message) Descriptor
deprecated
func (*Message) GetLocation ¶
func (*Message) GetService ¶
func (*Message) GetVaccineType ¶
func (*Message) ProtoMessage ¶
func (*Message) ProtoMessage()
func (*Message) ProtoReflect ¶
func (x *Message) ProtoReflect() protoreflect.Message
type MessengerClient ¶
type MessengerClient interface {
RegisterMessage(ctx context.Context, in *Message, opts ...grpc.CallOption) (*Confirmation, error)
}
MessengerClient is the client API for Messenger 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 NewMessengerClient ¶
func NewMessengerClient(cc grpc.ClientConnInterface) MessengerClient
type MessengerServer ¶
type MessengerServer interface { RegisterMessage(context.Context, *Message) (*Confirmation, error) // contains filtered or unexported methods }
MessengerServer is the server API for Messenger service. All implementations must embed UnimplementedMessengerServer for forward compatibility
type UnimplementedMessengerServer ¶
type UnimplementedMessengerServer struct { }
UnimplementedMessengerServer must be embedded to have forward compatible implementations.
func (UnimplementedMessengerServer) RegisterMessage ¶
func (UnimplementedMessengerServer) RegisterMessage(context.Context, *Message) (*Confirmation, error)
type UnsafeMessengerServer ¶
type UnsafeMessengerServer interface {
// contains filtered or unexported methods
}
UnsafeMessengerServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to MessengerServer will result in compilation errors.