github.com/Finschia/finschia-sdk@v0.48.1/client/grpc/tmservice/query.pb.gw.go (about)

     1  // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT.
     2  // source: cosmos/base/tendermint/v1beta1/query.proto
     3  
     4  /*
     5  Package tmservice is a reverse proxy.
     6  
     7  It translates gRPC into RESTful JSON APIs.
     8  */
     9  package tmservice
    10  
    11  import (
    12  	"context"
    13  	"io"
    14  	"net/http"
    15  
    16  	"github.com/golang/protobuf/descriptor"
    17  	"github.com/golang/protobuf/proto"
    18  	"github.com/grpc-ecosystem/grpc-gateway/runtime"
    19  	"github.com/grpc-ecosystem/grpc-gateway/utilities"
    20  	"google.golang.org/grpc"
    21  	"google.golang.org/grpc/codes"
    22  	"google.golang.org/grpc/grpclog"
    23  	"google.golang.org/grpc/status"
    24  )
    25  
    26  // Suppress "imported and not used" errors
    27  var _ codes.Code
    28  var _ io.Reader
    29  var _ status.Status
    30  var _ = runtime.String
    31  var _ = utilities.NewDoubleArray
    32  var _ = descriptor.ForMessage
    33  
    34  func request_Service_GetNodeInfo_0(ctx context.Context, marshaler runtime.Marshaler, client ServiceClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
    35  	var protoReq GetNodeInfoRequest
    36  	var metadata runtime.ServerMetadata
    37  
    38  	msg, err := client.GetNodeInfo(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))
    39  	return msg, metadata, err
    40  
    41  }
    42  
    43  func local_request_Service_GetNodeInfo_0(ctx context.Context, marshaler runtime.Marshaler, server ServiceServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
    44  	var protoReq GetNodeInfoRequest
    45  	var metadata runtime.ServerMetadata
    46  
    47  	msg, err := server.GetNodeInfo(ctx, &protoReq)
    48  	return msg, metadata, err
    49  
    50  }
    51  
    52  func request_Service_GetSyncing_0(ctx context.Context, marshaler runtime.Marshaler, client ServiceClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
    53  	var protoReq GetSyncingRequest
    54  	var metadata runtime.ServerMetadata
    55  
    56  	msg, err := client.GetSyncing(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))
    57  	return msg, metadata, err
    58  
    59  }
    60  
    61  func local_request_Service_GetSyncing_0(ctx context.Context, marshaler runtime.Marshaler, server ServiceServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
    62  	var protoReq GetSyncingRequest
    63  	var metadata runtime.ServerMetadata
    64  
    65  	msg, err := server.GetSyncing(ctx, &protoReq)
    66  	return msg, metadata, err
    67  
    68  }
    69  
    70  func request_Service_GetLatestBlock_0(ctx context.Context, marshaler runtime.Marshaler, client ServiceClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
    71  	var protoReq GetLatestBlockRequest
    72  	var metadata runtime.ServerMetadata
    73  
    74  	msg, err := client.GetLatestBlock(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))
    75  	return msg, metadata, err
    76  
    77  }
    78  
    79  func local_request_Service_GetLatestBlock_0(ctx context.Context, marshaler runtime.Marshaler, server ServiceServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
    80  	var protoReq GetLatestBlockRequest
    81  	var metadata runtime.ServerMetadata
    82  
    83  	msg, err := server.GetLatestBlock(ctx, &protoReq)
    84  	return msg, metadata, err
    85  
    86  }
    87  
    88  func request_Service_GetBlockByHeight_0(ctx context.Context, marshaler runtime.Marshaler, client ServiceClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
    89  	var protoReq GetBlockByHeightRequest
    90  	var metadata runtime.ServerMetadata
    91  
    92  	var (
    93  		val string
    94  		ok  bool
    95  		err error
    96  		_   = err
    97  	)
    98  
    99  	val, ok = pathParams["height"]
   100  	if !ok {
   101  		return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "height")
   102  	}
   103  
   104  	protoReq.Height, err = runtime.Int64(val)
   105  
   106  	if err != nil {
   107  		return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "height", err)
   108  	}
   109  
   110  	msg, err := client.GetBlockByHeight(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))
   111  	return msg, metadata, err
   112  
   113  }
   114  
   115  func local_request_Service_GetBlockByHeight_0(ctx context.Context, marshaler runtime.Marshaler, server ServiceServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
   116  	var protoReq GetBlockByHeightRequest
   117  	var metadata runtime.ServerMetadata
   118  
   119  	var (
   120  		val string
   121  		ok  bool
   122  		err error
   123  		_   = err
   124  	)
   125  
   126  	val, ok = pathParams["height"]
   127  	if !ok {
   128  		return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "height")
   129  	}
   130  
   131  	protoReq.Height, err = runtime.Int64(val)
   132  
   133  	if err != nil {
   134  		return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "height", err)
   135  	}
   136  
   137  	msg, err := server.GetBlockByHeight(ctx, &protoReq)
   138  	return msg, metadata, err
   139  
   140  }
   141  
   142  var (
   143  	filter_Service_GetLatestValidatorSet_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)}
   144  )
   145  
   146  func request_Service_GetLatestValidatorSet_0(ctx context.Context, marshaler runtime.Marshaler, client ServiceClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
   147  	var protoReq GetLatestValidatorSetRequest
   148  	var metadata runtime.ServerMetadata
   149  
   150  	if err := req.ParseForm(); err != nil {
   151  		return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)
   152  	}
   153  	if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Service_GetLatestValidatorSet_0); err != nil {
   154  		return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)
   155  	}
   156  
   157  	msg, err := client.GetLatestValidatorSet(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))
   158  	return msg, metadata, err
   159  
   160  }
   161  
   162  func local_request_Service_GetLatestValidatorSet_0(ctx context.Context, marshaler runtime.Marshaler, server ServiceServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
   163  	var protoReq GetLatestValidatorSetRequest
   164  	var metadata runtime.ServerMetadata
   165  
   166  	if err := req.ParseForm(); err != nil {
   167  		return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)
   168  	}
   169  	if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Service_GetLatestValidatorSet_0); err != nil {
   170  		return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)
   171  	}
   172  
   173  	msg, err := server.GetLatestValidatorSet(ctx, &protoReq)
   174  	return msg, metadata, err
   175  
   176  }
   177  
   178  var (
   179  	filter_Service_GetValidatorSetByHeight_0 = &utilities.DoubleArray{Encoding: map[string]int{"height": 0}, Base: []int{1, 1, 0}, Check: []int{0, 1, 2}}
   180  )
   181  
   182  func request_Service_GetValidatorSetByHeight_0(ctx context.Context, marshaler runtime.Marshaler, client ServiceClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
   183  	var protoReq GetValidatorSetByHeightRequest
   184  	var metadata runtime.ServerMetadata
   185  
   186  	var (
   187  		val string
   188  		ok  bool
   189  		err error
   190  		_   = err
   191  	)
   192  
   193  	val, ok = pathParams["height"]
   194  	if !ok {
   195  		return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "height")
   196  	}
   197  
   198  	protoReq.Height, err = runtime.Int64(val)
   199  
   200  	if err != nil {
   201  		return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "height", err)
   202  	}
   203  
   204  	if err := req.ParseForm(); err != nil {
   205  		return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)
   206  	}
   207  	if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Service_GetValidatorSetByHeight_0); err != nil {
   208  		return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)
   209  	}
   210  
   211  	msg, err := client.GetValidatorSetByHeight(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))
   212  	return msg, metadata, err
   213  
   214  }
   215  
   216  func local_request_Service_GetValidatorSetByHeight_0(ctx context.Context, marshaler runtime.Marshaler, server ServiceServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {
   217  	var protoReq GetValidatorSetByHeightRequest
   218  	var metadata runtime.ServerMetadata
   219  
   220  	var (
   221  		val string
   222  		ok  bool
   223  		err error
   224  		_   = err
   225  	)
   226  
   227  	val, ok = pathParams["height"]
   228  	if !ok {
   229  		return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "height")
   230  	}
   231  
   232  	protoReq.Height, err = runtime.Int64(val)
   233  
   234  	if err != nil {
   235  		return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "height", err)
   236  	}
   237  
   238  	if err := req.ParseForm(); err != nil {
   239  		return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)
   240  	}
   241  	if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Service_GetValidatorSetByHeight_0); err != nil {
   242  		return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)
   243  	}
   244  
   245  	msg, err := server.GetValidatorSetByHeight(ctx, &protoReq)
   246  	return msg, metadata, err
   247  
   248  }
   249  
   250  // RegisterServiceHandlerServer registers the http handlers for service Service to "mux".
   251  // UnaryRPC     :call ServiceServer directly.
   252  // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906.
   253  // Note that using this registration option will cause many gRPC library features (such as grpc.SendHeader, etc) to stop working. Consider using RegisterServiceHandlerFromEndpoint instead.
   254  func RegisterServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server ServiceServer) error {
   255  
   256  	mux.Handle("GET", pattern_Service_GetNodeInfo_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
   257  		ctx, cancel := context.WithCancel(req.Context())
   258  		defer cancel()
   259  		inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
   260  		rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)
   261  		if err != nil {
   262  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   263  			return
   264  		}
   265  		resp, md, err := local_request_Service_GetNodeInfo_0(rctx, inboundMarshaler, server, req, pathParams)
   266  		ctx = runtime.NewServerMetadataContext(ctx, md)
   267  		if err != nil {
   268  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   269  			return
   270  		}
   271  
   272  		forward_Service_GetNodeInfo_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
   273  
   274  	})
   275  
   276  	mux.Handle("GET", pattern_Service_GetSyncing_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
   277  		ctx, cancel := context.WithCancel(req.Context())
   278  		defer cancel()
   279  		inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
   280  		rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)
   281  		if err != nil {
   282  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   283  			return
   284  		}
   285  		resp, md, err := local_request_Service_GetSyncing_0(rctx, inboundMarshaler, server, req, pathParams)
   286  		ctx = runtime.NewServerMetadataContext(ctx, md)
   287  		if err != nil {
   288  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   289  			return
   290  		}
   291  
   292  		forward_Service_GetSyncing_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
   293  
   294  	})
   295  
   296  	mux.Handle("GET", pattern_Service_GetLatestBlock_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
   297  		ctx, cancel := context.WithCancel(req.Context())
   298  		defer cancel()
   299  		inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
   300  		rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)
   301  		if err != nil {
   302  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   303  			return
   304  		}
   305  		resp, md, err := local_request_Service_GetLatestBlock_0(rctx, inboundMarshaler, server, req, pathParams)
   306  		ctx = runtime.NewServerMetadataContext(ctx, md)
   307  		if err != nil {
   308  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   309  			return
   310  		}
   311  
   312  		forward_Service_GetLatestBlock_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
   313  
   314  	})
   315  
   316  	mux.Handle("GET", pattern_Service_GetBlockByHeight_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
   317  		ctx, cancel := context.WithCancel(req.Context())
   318  		defer cancel()
   319  		inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
   320  		rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)
   321  		if err != nil {
   322  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   323  			return
   324  		}
   325  		resp, md, err := local_request_Service_GetBlockByHeight_0(rctx, inboundMarshaler, server, req, pathParams)
   326  		ctx = runtime.NewServerMetadataContext(ctx, md)
   327  		if err != nil {
   328  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   329  			return
   330  		}
   331  
   332  		forward_Service_GetBlockByHeight_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
   333  
   334  	})
   335  
   336  	mux.Handle("GET", pattern_Service_GetLatestValidatorSet_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
   337  		ctx, cancel := context.WithCancel(req.Context())
   338  		defer cancel()
   339  		inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
   340  		rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)
   341  		if err != nil {
   342  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   343  			return
   344  		}
   345  		resp, md, err := local_request_Service_GetLatestValidatorSet_0(rctx, inboundMarshaler, server, req, pathParams)
   346  		ctx = runtime.NewServerMetadataContext(ctx, md)
   347  		if err != nil {
   348  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   349  			return
   350  		}
   351  
   352  		forward_Service_GetLatestValidatorSet_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
   353  
   354  	})
   355  
   356  	mux.Handle("GET", pattern_Service_GetValidatorSetByHeight_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
   357  		ctx, cancel := context.WithCancel(req.Context())
   358  		defer cancel()
   359  		inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
   360  		rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)
   361  		if err != nil {
   362  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   363  			return
   364  		}
   365  		resp, md, err := local_request_Service_GetValidatorSetByHeight_0(rctx, inboundMarshaler, server, req, pathParams)
   366  		ctx = runtime.NewServerMetadataContext(ctx, md)
   367  		if err != nil {
   368  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   369  			return
   370  		}
   371  
   372  		forward_Service_GetValidatorSetByHeight_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
   373  
   374  	})
   375  
   376  	return nil
   377  }
   378  
   379  // RegisterServiceHandlerFromEndpoint is same as RegisterServiceHandler but
   380  // automatically dials to "endpoint" and closes the connection when "ctx" gets done.
   381  func RegisterServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) {
   382  	conn, err := grpc.Dial(endpoint, opts...)
   383  	if err != nil {
   384  		return err
   385  	}
   386  	defer func() {
   387  		if err != nil {
   388  			if cerr := conn.Close(); cerr != nil {
   389  				grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr)
   390  			}
   391  			return
   392  		}
   393  		go func() {
   394  			<-ctx.Done()
   395  			if cerr := conn.Close(); cerr != nil {
   396  				grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr)
   397  			}
   398  		}()
   399  	}()
   400  
   401  	return RegisterServiceHandler(ctx, mux, conn)
   402  }
   403  
   404  // RegisterServiceHandler registers the http handlers for service Service to "mux".
   405  // The handlers forward requests to the grpc endpoint over "conn".
   406  func RegisterServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error {
   407  	return RegisterServiceHandlerClient(ctx, mux, NewServiceClient(conn))
   408  }
   409  
   410  // RegisterServiceHandlerClient registers the http handlers for service Service
   411  // to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "ServiceClient".
   412  // Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "ServiceClient"
   413  // doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in
   414  // "ServiceClient" to call the correct interceptors.
   415  func RegisterServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client ServiceClient) error {
   416  
   417  	mux.Handle("GET", pattern_Service_GetNodeInfo_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
   418  		ctx, cancel := context.WithCancel(req.Context())
   419  		defer cancel()
   420  		inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
   421  		rctx, err := runtime.AnnotateContext(ctx, mux, req)
   422  		if err != nil {
   423  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   424  			return
   425  		}
   426  		resp, md, err := request_Service_GetNodeInfo_0(rctx, inboundMarshaler, client, req, pathParams)
   427  		ctx = runtime.NewServerMetadataContext(ctx, md)
   428  		if err != nil {
   429  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   430  			return
   431  		}
   432  
   433  		forward_Service_GetNodeInfo_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
   434  
   435  	})
   436  
   437  	mux.Handle("GET", pattern_Service_GetSyncing_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
   438  		ctx, cancel := context.WithCancel(req.Context())
   439  		defer cancel()
   440  		inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
   441  		rctx, err := runtime.AnnotateContext(ctx, mux, req)
   442  		if err != nil {
   443  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   444  			return
   445  		}
   446  		resp, md, err := request_Service_GetSyncing_0(rctx, inboundMarshaler, client, req, pathParams)
   447  		ctx = runtime.NewServerMetadataContext(ctx, md)
   448  		if err != nil {
   449  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   450  			return
   451  		}
   452  
   453  		forward_Service_GetSyncing_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
   454  
   455  	})
   456  
   457  	mux.Handle("GET", pattern_Service_GetLatestBlock_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
   458  		ctx, cancel := context.WithCancel(req.Context())
   459  		defer cancel()
   460  		inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
   461  		rctx, err := runtime.AnnotateContext(ctx, mux, req)
   462  		if err != nil {
   463  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   464  			return
   465  		}
   466  		resp, md, err := request_Service_GetLatestBlock_0(rctx, inboundMarshaler, client, req, pathParams)
   467  		ctx = runtime.NewServerMetadataContext(ctx, md)
   468  		if err != nil {
   469  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   470  			return
   471  		}
   472  
   473  		forward_Service_GetLatestBlock_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
   474  
   475  	})
   476  
   477  	mux.Handle("GET", pattern_Service_GetBlockByHeight_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
   478  		ctx, cancel := context.WithCancel(req.Context())
   479  		defer cancel()
   480  		inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
   481  		rctx, err := runtime.AnnotateContext(ctx, mux, req)
   482  		if err != nil {
   483  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   484  			return
   485  		}
   486  		resp, md, err := request_Service_GetBlockByHeight_0(rctx, inboundMarshaler, client, req, pathParams)
   487  		ctx = runtime.NewServerMetadataContext(ctx, md)
   488  		if err != nil {
   489  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   490  			return
   491  		}
   492  
   493  		forward_Service_GetBlockByHeight_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
   494  
   495  	})
   496  
   497  	mux.Handle("GET", pattern_Service_GetLatestValidatorSet_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
   498  		ctx, cancel := context.WithCancel(req.Context())
   499  		defer cancel()
   500  		inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
   501  		rctx, err := runtime.AnnotateContext(ctx, mux, req)
   502  		if err != nil {
   503  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   504  			return
   505  		}
   506  		resp, md, err := request_Service_GetLatestValidatorSet_0(rctx, inboundMarshaler, client, req, pathParams)
   507  		ctx = runtime.NewServerMetadataContext(ctx, md)
   508  		if err != nil {
   509  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   510  			return
   511  		}
   512  
   513  		forward_Service_GetLatestValidatorSet_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
   514  
   515  	})
   516  
   517  	mux.Handle("GET", pattern_Service_GetValidatorSetByHeight_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {
   518  		ctx, cancel := context.WithCancel(req.Context())
   519  		defer cancel()
   520  		inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)
   521  		rctx, err := runtime.AnnotateContext(ctx, mux, req)
   522  		if err != nil {
   523  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   524  			return
   525  		}
   526  		resp, md, err := request_Service_GetValidatorSetByHeight_0(rctx, inboundMarshaler, client, req, pathParams)
   527  		ctx = runtime.NewServerMetadataContext(ctx, md)
   528  		if err != nil {
   529  			runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)
   530  			return
   531  		}
   532  
   533  		forward_Service_GetValidatorSetByHeight_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)
   534  
   535  	})
   536  
   537  	return nil
   538  }
   539  
   540  var (
   541  	pattern_Service_GetNodeInfo_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"cosmos", "base", "tendermint", "v1beta1", "node_info"}, "", runtime.AssumeColonVerbOpt(false)))
   542  
   543  	pattern_Service_GetSyncing_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"cosmos", "base", "tendermint", "v1beta1", "syncing"}, "", runtime.AssumeColonVerbOpt(false)))
   544  
   545  	pattern_Service_GetLatestBlock_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 2, 5}, []string{"cosmos", "base", "tendermint", "v1beta1", "blocks", "latest"}, "", runtime.AssumeColonVerbOpt(false)))
   546  
   547  	pattern_Service_GetBlockByHeight_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5}, []string{"cosmos", "base", "tendermint", "v1beta1", "blocks", "height"}, "", runtime.AssumeColonVerbOpt(false)))
   548  
   549  	pattern_Service_GetLatestValidatorSet_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 2, 5}, []string{"cosmos", "base", "tendermint", "v1beta1", "validatorsets", "latest"}, "", runtime.AssumeColonVerbOpt(false)))
   550  
   551  	pattern_Service_GetValidatorSetByHeight_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 5}, []string{"cosmos", "base", "tendermint", "v1beta1", "validatorsets", "height"}, "", runtime.AssumeColonVerbOpt(false)))
   552  )
   553  
   554  var (
   555  	forward_Service_GetNodeInfo_0 = runtime.ForwardResponseMessage
   556  
   557  	forward_Service_GetSyncing_0 = runtime.ForwardResponseMessage
   558  
   559  	forward_Service_GetLatestBlock_0 = runtime.ForwardResponseMessage
   560  
   561  	forward_Service_GetBlockByHeight_0 = runtime.ForwardResponseMessage
   562  
   563  	forward_Service_GetLatestValidatorSet_0 = runtime.ForwardResponseMessage
   564  
   565  	forward_Service_GetValidatorSetByHeight_0 = runtime.ForwardResponseMessage
   566  )