Documentation ¶
Overview ¶
Package translatorpb is a generated protocol buffer package.
It is generated from these files:
translator.proto
It has these top-level messages:
TranslateRequest TranslateResponse
Index ¶
- func RegisterTranslatorServiceServer(s *grpc.Server, srv TranslatorServiceServer)
- type TranslateRequest
- func (*TranslateRequest) Descriptor() ([]byte, []int)
- func (m *TranslateRequest) GetArguments() []string
- func (m *TranslateRequest) GetLanguage() string
- func (m *TranslateRequest) GetMessage() string
- func (*TranslateRequest) ProtoMessage()
- func (m *TranslateRequest) Reset()
- func (m *TranslateRequest) String() string
- type TranslateResponse
- type TranslatorServiceClient
- type TranslatorServiceServer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterTranslatorServiceServer ¶
func RegisterTranslatorServiceServer(s *grpc.Server, srv TranslatorServiceServer)
Types ¶
type TranslateRequest ¶
type TranslateRequest struct { Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"` Language string `protobuf:"bytes,2,opt,name=language,proto3" json:"language,omitempty"` Arguments []string `protobuf:"bytes,3,rep,name=arguments" json:"arguments,omitempty"` }
func (*TranslateRequest) Descriptor ¶
func (*TranslateRequest) Descriptor() ([]byte, []int)
func (*TranslateRequest) GetArguments ¶
func (m *TranslateRequest) GetArguments() []string
func (*TranslateRequest) GetLanguage ¶
func (m *TranslateRequest) GetLanguage() string
func (*TranslateRequest) GetMessage ¶
func (m *TranslateRequest) GetMessage() string
func (*TranslateRequest) ProtoMessage ¶
func (*TranslateRequest) ProtoMessage()
func (*TranslateRequest) Reset ¶
func (m *TranslateRequest) Reset()
func (*TranslateRequest) String ¶
func (m *TranslateRequest) String() string
type TranslateResponse ¶
type TranslateResponse struct { Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"` ErrMsg string `protobuf:"bytes,2,opt,name=err_msg,json=errMsg,proto3" json:"err_msg,omitempty"` }
func (*TranslateResponse) Descriptor ¶
func (*TranslateResponse) Descriptor() ([]byte, []int)
func (*TranslateResponse) GetErrMsg ¶
func (m *TranslateResponse) GetErrMsg() string
func (*TranslateResponse) GetMessage ¶
func (m *TranslateResponse) GetMessage() string
func (*TranslateResponse) ProtoMessage ¶
func (*TranslateResponse) ProtoMessage()
func (*TranslateResponse) Reset ¶
func (m *TranslateResponse) Reset()
func (*TranslateResponse) String ¶
func (m *TranslateResponse) String() string
type TranslatorServiceClient ¶
type TranslatorServiceClient interface {
Translate(ctx context.Context, in *TranslateRequest, opts ...grpc.CallOption) (*TranslateResponse, error)
}
func NewTranslatorServiceClient ¶
func NewTranslatorServiceClient(cc *grpc.ClientConn) TranslatorServiceClient
type TranslatorServiceServer ¶
type TranslatorServiceServer interface {
Translate(context.Context, *TranslateRequest) (*TranslateResponse, error)
}
Click to show internal directories.
Click to hide internal directories.