Documentation ¶
Index ¶
- Variables
- func RegisterEmailServer(s grpc.ServiceRegistrar, srv EmailServer)
- type EmailClient
- type EmailServer
- type SendEmailRequest
- func (*SendEmailRequest) Descriptor() ([]byte, []int)deprecated
- func (x *SendEmailRequest) GetData() string
- func (x *SendEmailRequest) GetEmail() string
- func (x *SendEmailRequest) GetType() string
- func (x *SendEmailRequest) GetUsername() string
- func (*SendEmailRequest) ProtoMessage()
- func (x *SendEmailRequest) ProtoReflect() protoreflect.Message
- func (x *SendEmailRequest) Reset()
- func (x *SendEmailRequest) String() string
- type UnimplementedEmailServer
- type UnsafeEmailServer
Constants ¶
This section is empty.
Variables ¶
var Email_ServiceDesc = grpc.ServiceDesc{ ServiceName: "email.Email", HandlerType: (*EmailServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "SendEmail", Handler: _Email_SendEmail_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "protocol/email.proto", }
Email_ServiceDesc is the grpc.ServiceDesc for Email service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_protocol_email_proto protoreflect.FileDescriptor
Functions ¶
func RegisterEmailServer ¶
func RegisterEmailServer(s grpc.ServiceRegistrar, srv EmailServer)
Types ¶
type EmailClient ¶
type EmailClient interface { // SendEmail send an email with the given information SendEmail(ctx context.Context, in *SendEmailRequest, opts ...grpc.CallOption) (*empty.Empty, error) }
EmailClient is the client API for Email 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 NewEmailClient ¶
func NewEmailClient(cc grpc.ClientConnInterface) EmailClient
type EmailServer ¶
type EmailServer interface { // SendEmail send an email with the given information SendEmail(context.Context, *SendEmailRequest) (*empty.Empty, error) // contains filtered or unexported methods }
EmailServer is the server API for Email service. All implementations must embed UnimplementedEmailServer for forward compatibility
type SendEmailRequest ¶
type SendEmailRequest struct { Email string `protobuf:"bytes,1,opt,name=Email,proto3" json:"Email,omitempty"` Username string `protobuf:"bytes,2,opt,name=Username,proto3" json:"Username,omitempty"` Type string `protobuf:"bytes,3,opt,name=Type,proto3" json:"Type,omitempty"` Data string `protobuf:"bytes,4,opt,name=Data,proto3" json:"Data,omitempty"` // contains filtered or unexported fields }
func (*SendEmailRequest) Descriptor
deprecated
func (*SendEmailRequest) Descriptor() ([]byte, []int)
Deprecated: Use SendEmailRequest.ProtoReflect.Descriptor instead.
func (*SendEmailRequest) GetData ¶
func (x *SendEmailRequest) GetData() string
func (*SendEmailRequest) GetEmail ¶
func (x *SendEmailRequest) GetEmail() string
func (*SendEmailRequest) GetType ¶
func (x *SendEmailRequest) GetType() string
func (*SendEmailRequest) GetUsername ¶
func (x *SendEmailRequest) GetUsername() string
func (*SendEmailRequest) ProtoMessage ¶
func (*SendEmailRequest) ProtoMessage()
func (*SendEmailRequest) ProtoReflect ¶
func (x *SendEmailRequest) ProtoReflect() protoreflect.Message
func (*SendEmailRequest) Reset ¶
func (x *SendEmailRequest) Reset()
func (*SendEmailRequest) String ¶
func (x *SendEmailRequest) String() string
type UnimplementedEmailServer ¶
type UnimplementedEmailServer struct { }
UnimplementedEmailServer must be embedded to have forward compatible implementations.
func (UnimplementedEmailServer) SendEmail ¶
func (UnimplementedEmailServer) SendEmail(context.Context, *SendEmailRequest) (*empty.Empty, error)
type UnsafeEmailServer ¶
type UnsafeEmailServer interface {
// contains filtered or unexported methods
}
UnsafeEmailServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to EmailServer will result in compilation errors.