123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323 |
- // Code generated by protoc-gen-go-grpc. DO NOT EDIT.
- // versions:
- // - protoc-gen-go-grpc v1.2.0
- // - protoc v3.12.4
- // source: v1/query.proto
- package v1
- import (
- context "context"
- request "git.sxidc.com/service-supports/dps-sdk/pb/v1/request"
- response "git.sxidc.com/service-supports/dps-sdk/pb/v1/response"
- grpc "google.golang.org/grpc"
- codes "google.golang.org/grpc/codes"
- status "google.golang.org/grpc/status"
- )
- // This is a compile-time assertion to ensure that this generated file
- // is compatible with the grpc package it is being compiled against.
- // Requires gRPC-Go v1.32.0 or later.
- const _ = grpc.SupportPackageIsVersion7
- // QueryServiceClient is the client API for QueryService 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.
- type QueryServiceClient interface {
- QueryByWhereAndOrderBy(ctx context.Context, in *request.QueryByWhereAndOrderByRequest, opts ...grpc.CallOption) (*response.QueryResponse, error)
- CommonQuery(ctx context.Context, in *request.CommonQueryRequest, opts ...grpc.CallOption) (*response.QueryResponse, error)
- QueryOnlyByWhereAndOrderBy(ctx context.Context, in *request.QueryByWhereAndOrderByRequest, opts ...grpc.CallOption) (*response.QueryOnlyResponse, error)
- CommonQueryOnly(ctx context.Context, in *request.CommonQueryRequest, opts ...grpc.CallOption) (*response.QueryOnlyResponse, error)
- QueryByKeys(ctx context.Context, in *request.QueryByKeysRequest, opts ...grpc.CallOption) (*response.QueryByKeysResponse, error)
- CountWhere(ctx context.Context, in *request.CountWhereRequest, opts ...grpc.CallOption) (*response.CountResponse, error)
- CommonCount(ctx context.Context, in *request.CommonCountRequest, opts ...grpc.CallOption) (*response.CountResponse, error)
- }
- type queryServiceClient struct {
- cc grpc.ClientConnInterface
- }
- func NewQueryServiceClient(cc grpc.ClientConnInterface) QueryServiceClient {
- return &queryServiceClient{cc}
- }
- func (c *queryServiceClient) QueryByWhereAndOrderBy(ctx context.Context, in *request.QueryByWhereAndOrderByRequest, opts ...grpc.CallOption) (*response.QueryResponse, error) {
- out := new(response.QueryResponse)
- err := c.cc.Invoke(ctx, "/v1.QueryService/QueryByWhereAndOrderBy", in, out, opts...)
- if err != nil {
- return nil, err
- }
- return out, nil
- }
- func (c *queryServiceClient) CommonQuery(ctx context.Context, in *request.CommonQueryRequest, opts ...grpc.CallOption) (*response.QueryResponse, error) {
- out := new(response.QueryResponse)
- err := c.cc.Invoke(ctx, "/v1.QueryService/CommonQuery", in, out, opts...)
- if err != nil {
- return nil, err
- }
- return out, nil
- }
- func (c *queryServiceClient) QueryOnlyByWhereAndOrderBy(ctx context.Context, in *request.QueryByWhereAndOrderByRequest, opts ...grpc.CallOption) (*response.QueryOnlyResponse, error) {
- out := new(response.QueryOnlyResponse)
- err := c.cc.Invoke(ctx, "/v1.QueryService/QueryOnlyByWhereAndOrderBy", in, out, opts...)
- if err != nil {
- return nil, err
- }
- return out, nil
- }
- func (c *queryServiceClient) CommonQueryOnly(ctx context.Context, in *request.CommonQueryRequest, opts ...grpc.CallOption) (*response.QueryOnlyResponse, error) {
- out := new(response.QueryOnlyResponse)
- err := c.cc.Invoke(ctx, "/v1.QueryService/CommonQueryOnly", in, out, opts...)
- if err != nil {
- return nil, err
- }
- return out, nil
- }
- func (c *queryServiceClient) QueryByKeys(ctx context.Context, in *request.QueryByKeysRequest, opts ...grpc.CallOption) (*response.QueryByKeysResponse, error) {
- out := new(response.QueryByKeysResponse)
- err := c.cc.Invoke(ctx, "/v1.QueryService/QueryByKeys", in, out, opts...)
- if err != nil {
- return nil, err
- }
- return out, nil
- }
- func (c *queryServiceClient) CountWhere(ctx context.Context, in *request.CountWhereRequest, opts ...grpc.CallOption) (*response.CountResponse, error) {
- out := new(response.CountResponse)
- err := c.cc.Invoke(ctx, "/v1.QueryService/CountWhere", in, out, opts...)
- if err != nil {
- return nil, err
- }
- return out, nil
- }
- func (c *queryServiceClient) CommonCount(ctx context.Context, in *request.CommonCountRequest, opts ...grpc.CallOption) (*response.CountResponse, error) {
- out := new(response.CountResponse)
- err := c.cc.Invoke(ctx, "/v1.QueryService/CommonCount", in, out, opts...)
- if err != nil {
- return nil, err
- }
- return out, nil
- }
- // QueryServiceServer is the server API for QueryService service.
- // All implementations must embed UnimplementedQueryServiceServer
- // for forward compatibility
- type QueryServiceServer interface {
- QueryByWhereAndOrderBy(context.Context, *request.QueryByWhereAndOrderByRequest) (*response.QueryResponse, error)
- CommonQuery(context.Context, *request.CommonQueryRequest) (*response.QueryResponse, error)
- QueryOnlyByWhereAndOrderBy(context.Context, *request.QueryByWhereAndOrderByRequest) (*response.QueryOnlyResponse, error)
- CommonQueryOnly(context.Context, *request.CommonQueryRequest) (*response.QueryOnlyResponse, error)
- QueryByKeys(context.Context, *request.QueryByKeysRequest) (*response.QueryByKeysResponse, error)
- CountWhere(context.Context, *request.CountWhereRequest) (*response.CountResponse, error)
- CommonCount(context.Context, *request.CommonCountRequest) (*response.CountResponse, error)
- mustEmbedUnimplementedQueryServiceServer()
- }
- // UnimplementedQueryServiceServer must be embedded to have forward compatible implementations.
- type UnimplementedQueryServiceServer struct {
- }
- func (UnimplementedQueryServiceServer) QueryByWhereAndOrderBy(context.Context, *request.QueryByWhereAndOrderByRequest) (*response.QueryResponse, error) {
- return nil, status.Errorf(codes.Unimplemented, "method QueryByWhereAndOrderBy not implemented")
- }
- func (UnimplementedQueryServiceServer) CommonQuery(context.Context, *request.CommonQueryRequest) (*response.QueryResponse, error) {
- return nil, status.Errorf(codes.Unimplemented, "method CommonQuery not implemented")
- }
- func (UnimplementedQueryServiceServer) QueryOnlyByWhereAndOrderBy(context.Context, *request.QueryByWhereAndOrderByRequest) (*response.QueryOnlyResponse, error) {
- return nil, status.Errorf(codes.Unimplemented, "method QueryOnlyByWhereAndOrderBy not implemented")
- }
- func (UnimplementedQueryServiceServer) CommonQueryOnly(context.Context, *request.CommonQueryRequest) (*response.QueryOnlyResponse, error) {
- return nil, status.Errorf(codes.Unimplemented, "method CommonQueryOnly not implemented")
- }
- func (UnimplementedQueryServiceServer) QueryByKeys(context.Context, *request.QueryByKeysRequest) (*response.QueryByKeysResponse, error) {
- return nil, status.Errorf(codes.Unimplemented, "method QueryByKeys not implemented")
- }
- func (UnimplementedQueryServiceServer) CountWhere(context.Context, *request.CountWhereRequest) (*response.CountResponse, error) {
- return nil, status.Errorf(codes.Unimplemented, "method CountWhere not implemented")
- }
- func (UnimplementedQueryServiceServer) CommonCount(context.Context, *request.CommonCountRequest) (*response.CountResponse, error) {
- return nil, status.Errorf(codes.Unimplemented, "method CommonCount not implemented")
- }
- func (UnimplementedQueryServiceServer) mustEmbedUnimplementedQueryServiceServer() {}
- // UnsafeQueryServiceServer may be embedded to opt out of forward compatibility for this service.
- // Use of this interface is not recommended, as added methods to QueryServiceServer will
- // result in compilation errors.
- type UnsafeQueryServiceServer interface {
- mustEmbedUnimplementedQueryServiceServer()
- }
- func RegisterQueryServiceServer(s grpc.ServiceRegistrar, srv QueryServiceServer) {
- s.RegisterService(&QueryService_ServiceDesc, srv)
- }
- func _QueryService_QueryByWhereAndOrderBy_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
- in := new(request.QueryByWhereAndOrderByRequest)
- if err := dec(in); err != nil {
- return nil, err
- }
- if interceptor == nil {
- return srv.(QueryServiceServer).QueryByWhereAndOrderBy(ctx, in)
- }
- info := &grpc.UnaryServerInfo{
- Server: srv,
- FullMethod: "/v1.QueryService/QueryByWhereAndOrderBy",
- }
- handler := func(ctx context.Context, req interface{}) (interface{}, error) {
- return srv.(QueryServiceServer).QueryByWhereAndOrderBy(ctx, req.(*request.QueryByWhereAndOrderByRequest))
- }
- return interceptor(ctx, in, info, handler)
- }
- func _QueryService_CommonQuery_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
- in := new(request.CommonQueryRequest)
- if err := dec(in); err != nil {
- return nil, err
- }
- if interceptor == nil {
- return srv.(QueryServiceServer).CommonQuery(ctx, in)
- }
- info := &grpc.UnaryServerInfo{
- Server: srv,
- FullMethod: "/v1.QueryService/CommonQuery",
- }
- handler := func(ctx context.Context, req interface{}) (interface{}, error) {
- return srv.(QueryServiceServer).CommonQuery(ctx, req.(*request.CommonQueryRequest))
- }
- return interceptor(ctx, in, info, handler)
- }
- func _QueryService_QueryOnlyByWhereAndOrderBy_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
- in := new(request.QueryByWhereAndOrderByRequest)
- if err := dec(in); err != nil {
- return nil, err
- }
- if interceptor == nil {
- return srv.(QueryServiceServer).QueryOnlyByWhereAndOrderBy(ctx, in)
- }
- info := &grpc.UnaryServerInfo{
- Server: srv,
- FullMethod: "/v1.QueryService/QueryOnlyByWhereAndOrderBy",
- }
- handler := func(ctx context.Context, req interface{}) (interface{}, error) {
- return srv.(QueryServiceServer).QueryOnlyByWhereAndOrderBy(ctx, req.(*request.QueryByWhereAndOrderByRequest))
- }
- return interceptor(ctx, in, info, handler)
- }
- func _QueryService_CommonQueryOnly_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
- in := new(request.CommonQueryRequest)
- if err := dec(in); err != nil {
- return nil, err
- }
- if interceptor == nil {
- return srv.(QueryServiceServer).CommonQueryOnly(ctx, in)
- }
- info := &grpc.UnaryServerInfo{
- Server: srv,
- FullMethod: "/v1.QueryService/CommonQueryOnly",
- }
- handler := func(ctx context.Context, req interface{}) (interface{}, error) {
- return srv.(QueryServiceServer).CommonQueryOnly(ctx, req.(*request.CommonQueryRequest))
- }
- return interceptor(ctx, in, info, handler)
- }
- func _QueryService_QueryByKeys_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
- in := new(request.QueryByKeysRequest)
- if err := dec(in); err != nil {
- return nil, err
- }
- if interceptor == nil {
- return srv.(QueryServiceServer).QueryByKeys(ctx, in)
- }
- info := &grpc.UnaryServerInfo{
- Server: srv,
- FullMethod: "/v1.QueryService/QueryByKeys",
- }
- handler := func(ctx context.Context, req interface{}) (interface{}, error) {
- return srv.(QueryServiceServer).QueryByKeys(ctx, req.(*request.QueryByKeysRequest))
- }
- return interceptor(ctx, in, info, handler)
- }
- func _QueryService_CountWhere_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
- in := new(request.CountWhereRequest)
- if err := dec(in); err != nil {
- return nil, err
- }
- if interceptor == nil {
- return srv.(QueryServiceServer).CountWhere(ctx, in)
- }
- info := &grpc.UnaryServerInfo{
- Server: srv,
- FullMethod: "/v1.QueryService/CountWhere",
- }
- handler := func(ctx context.Context, req interface{}) (interface{}, error) {
- return srv.(QueryServiceServer).CountWhere(ctx, req.(*request.CountWhereRequest))
- }
- return interceptor(ctx, in, info, handler)
- }
- func _QueryService_CommonCount_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
- in := new(request.CommonCountRequest)
- if err := dec(in); err != nil {
- return nil, err
- }
- if interceptor == nil {
- return srv.(QueryServiceServer).CommonCount(ctx, in)
- }
- info := &grpc.UnaryServerInfo{
- Server: srv,
- FullMethod: "/v1.QueryService/CommonCount",
- }
- handler := func(ctx context.Context, req interface{}) (interface{}, error) {
- return srv.(QueryServiceServer).CommonCount(ctx, req.(*request.CommonCountRequest))
- }
- return interceptor(ctx, in, info, handler)
- }
- // QueryService_ServiceDesc is the grpc.ServiceDesc for QueryService service.
- // It's only intended for direct use with grpc.RegisterService,
- // and not to be introspected or modified (even as a copy)
- var QueryService_ServiceDesc = grpc.ServiceDesc{
- ServiceName: "v1.QueryService",
- HandlerType: (*QueryServiceServer)(nil),
- Methods: []grpc.MethodDesc{
- {
- MethodName: "QueryByWhereAndOrderBy",
- Handler: _QueryService_QueryByWhereAndOrderBy_Handler,
- },
- {
- MethodName: "CommonQuery",
- Handler: _QueryService_CommonQuery_Handler,
- },
- {
- MethodName: "QueryOnlyByWhereAndOrderBy",
- Handler: _QueryService_QueryOnlyByWhereAndOrderBy_Handler,
- },
- {
- MethodName: "CommonQueryOnly",
- Handler: _QueryService_CommonQueryOnly_Handler,
- },
- {
- MethodName: "QueryByKeys",
- Handler: _QueryService_QueryByKeys_Handler,
- },
- {
- MethodName: "CountWhere",
- Handler: _QueryService_CountWhere_Handler,
- },
- {
- MethodName: "CommonCount",
- Handler: _QueryService_CommonCount_Handler,
- },
- },
- Streams: []grpc.StreamDesc{},
- Metadata: "v1/query.proto",
- }
|