Documentation ¶
Index ¶
- func RegisterSearchServer(s *grpc.Server, srv SearchServer)
- type FTRSearchRep
- func (*FTRSearchRep) Descriptor() ([]byte, []int)
- func (m *FTRSearchRep) GetResult() string
- func (*FTRSearchRep) ProtoMessage()
- func (m *FTRSearchRep) Reset()
- func (m *FTRSearchRep) String() string
- func (m *FTRSearchRep) XXX_DiscardUnknown()
- func (m *FTRSearchRep) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *FTRSearchRep) XXX_Merge(src proto.Message)
- func (m *FTRSearchRep) XXX_Size() int
- func (m *FTRSearchRep) XXX_Unmarshal(b []byte) error
- type FTRSearchReq
- func (*FTRSearchReq) Descriptor() ([]byte, []int)
- func (m *FTRSearchReq) GetKey() string
- func (*FTRSearchReq) ProtoMessage()
- func (m *FTRSearchReq) Reset()
- func (m *FTRSearchReq) String() string
- func (m *FTRSearchReq) XXX_DiscardUnknown()
- func (m *FTRSearchReq) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *FTRSearchReq) XXX_Merge(src proto.Message)
- func (m *FTRSearchReq) XXX_Size() int
- func (m *FTRSearchReq) XXX_Unmarshal(b []byte) error
- type SearchClient
- type SearchServer
- type SearchService
- type UnimplementedSearchServer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterSearchServer ¶
func RegisterSearchServer(s *grpc.Server, srv SearchServer)
Types ¶
type FTRSearchRep ¶
type FTRSearchRep struct { Result string `protobuf:"bytes,1,opt,name=result,proto3" json:"result,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
HelloResponse 响应结构
func (*FTRSearchRep) Descriptor ¶
func (*FTRSearchRep) Descriptor() ([]byte, []int)
func (*FTRSearchRep) GetResult ¶
func (m *FTRSearchRep) GetResult() string
func (*FTRSearchRep) ProtoMessage ¶
func (*FTRSearchRep) ProtoMessage()
func (*FTRSearchRep) Reset ¶
func (m *FTRSearchRep) Reset()
func (*FTRSearchRep) String ¶
func (m *FTRSearchRep) String() string
func (*FTRSearchRep) XXX_DiscardUnknown ¶
func (m *FTRSearchRep) XXX_DiscardUnknown()
func (*FTRSearchRep) XXX_Marshal ¶
func (m *FTRSearchRep) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*FTRSearchRep) XXX_Merge ¶
func (m *FTRSearchRep) XXX_Merge(src proto.Message)
func (*FTRSearchRep) XXX_Size ¶
func (m *FTRSearchRep) XXX_Size() int
func (*FTRSearchRep) XXX_Unmarshal ¶
func (m *FTRSearchRep) XXX_Unmarshal(b []byte) error
type FTRSearchReq ¶
type FTRSearchReq struct { Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
HelloRequest 请求结构
func (*FTRSearchReq) Descriptor ¶
func (*FTRSearchReq) Descriptor() ([]byte, []int)
func (*FTRSearchReq) GetKey ¶
func (m *FTRSearchReq) GetKey() string
func (*FTRSearchReq) ProtoMessage ¶
func (*FTRSearchReq) ProtoMessage()
func (*FTRSearchReq) Reset ¶
func (m *FTRSearchReq) Reset()
func (*FTRSearchReq) String ¶
func (m *FTRSearchReq) String() string
func (*FTRSearchReq) XXX_DiscardUnknown ¶
func (m *FTRSearchReq) XXX_DiscardUnknown()
func (*FTRSearchReq) XXX_Marshal ¶
func (m *FTRSearchReq) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*FTRSearchReq) XXX_Merge ¶
func (m *FTRSearchReq) XXX_Merge(src proto.Message)
func (*FTRSearchReq) XXX_Size ¶
func (m *FTRSearchReq) XXX_Size() int
func (*FTRSearchReq) XXX_Unmarshal ¶
func (m *FTRSearchReq) XXX_Unmarshal(b []byte) error
type SearchClient ¶
type SearchClient interface { // 全文检索 FTRSearch(ctx context.Context, in *FTRSearchReq, opts ...grpc.CallOption) (*FTRSearchRep, error) }
SearchClient is the client API for Search service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewSearchClient ¶
func NewSearchClient(cc *grpc.ClientConn) SearchClient
type SearchServer ¶
type SearchServer interface { // 全文检索 FTRSearch(context.Context, *FTRSearchReq) (*FTRSearchRep, error) }
SearchServer is the server API for Search service.
type SearchService ¶
type SearchService struct{}
定义helloService并实现约定的接口
func (SearchService) FTRSearch ¶
func (h SearchService) FTRSearch(ctx context.Context, in *FTRSearchReq) (*FTRSearchRep, error)
SayHello 实现Hello服务接口
type UnimplementedSearchServer ¶
type UnimplementedSearchServer struct { }
UnimplementedSearchServer can be embedded to have forward compatible implementations.
func (*UnimplementedSearchServer) FTRSearch ¶
func (*UnimplementedSearchServer) FTRSearch(ctx context.Context, req *FTRSearchReq) (*FTRSearchRep, error)
Click to show internal directories.
Click to hide internal directories.