curl_grpc.pb.go 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111
  1. // Code generated by protoc-gen-go-grpc. DO NOT EDIT.
  2. // versions:
  3. // - protoc-gen-go-grpc v1.3.0
  4. // - protoc v4.23.3
  5. // source: curl.proto
  6. package curl
  7. import (
  8. context "context"
  9. grpc "google.golang.org/grpc"
  10. codes "google.golang.org/grpc/codes"
  11. status "google.golang.org/grpc/status"
  12. )
  13. // This is a compile-time assertion to ensure that this generated file
  14. // is compatible with the grpc package it is being compiled against.
  15. // Requires gRPC-Go v1.32.0 or later.
  16. const _ = grpc.SupportPackageIsVersion7
  17. const (
  18. CurlWithResolve_CurlWithResolveParam_FullMethodName = "/curl.CurlWithResolve/CurlWithResolveParam"
  19. )
  20. // CurlWithResolveClient is the client API for CurlWithResolve service.
  21. //
  22. // 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.
  23. type CurlWithResolveClient interface {
  24. // Sends a greeting
  25. CurlWithResolveParam(ctx context.Context, in *CurlRequest, opts ...grpc.CallOption) (*CurlReply, error)
  26. }
  27. type curlWithResolveClient struct {
  28. cc grpc.ClientConnInterface
  29. }
  30. func NewCurlWithResolveClient(cc grpc.ClientConnInterface) CurlWithResolveClient {
  31. return &curlWithResolveClient{cc}
  32. }
  33. func (c *curlWithResolveClient) CurlWithResolveParam(ctx context.Context, in *CurlRequest, opts ...grpc.CallOption) (*CurlReply, error) {
  34. out := new(CurlReply)
  35. err := c.cc.Invoke(ctx, CurlWithResolve_CurlWithResolveParam_FullMethodName, in, out, opts...)
  36. if err != nil {
  37. return nil, err
  38. }
  39. return out, nil
  40. }
  41. // CurlWithResolveServer is the server API for CurlWithResolve service.
  42. // All implementations must embed UnimplementedCurlWithResolveServer
  43. // for forward compatibility
  44. type CurlWithResolveServer interface {
  45. // Sends a greeting
  46. CurlWithResolveParam(context.Context, *CurlRequest) (*CurlReply, error)
  47. mustEmbedUnimplementedCurlWithResolveServer()
  48. }
  49. // UnimplementedCurlWithResolveServer must be embedded to have forward compatible implementations.
  50. type UnimplementedCurlWithResolveServer struct {
  51. }
  52. func (UnimplementedCurlWithResolveServer) CurlWithResolveParam(context.Context, *CurlRequest) (*CurlReply, error) {
  53. return nil, status.Errorf(codes.Unimplemented, "method CurlWithResolveParam not implemented")
  54. }
  55. func (UnimplementedCurlWithResolveServer) mustEmbedUnimplementedCurlWithResolveServer() {}
  56. // UnsafeCurlWithResolveServer may be embedded to opt out of forward compatibility for this service.
  57. // Use of this interface is not recommended, as added methods to CurlWithResolveServer will
  58. // result in compilation errors.
  59. type UnsafeCurlWithResolveServer interface {
  60. mustEmbedUnimplementedCurlWithResolveServer()
  61. }
  62. func RegisterCurlWithResolveServer(s grpc.ServiceRegistrar, srv CurlWithResolveServer) {
  63. s.RegisterService(&CurlWithResolve_ServiceDesc, srv)
  64. }
  65. func _CurlWithResolve_CurlWithResolveParam_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  66. in := new(CurlRequest)
  67. if err := dec(in); err != nil {
  68. return nil, err
  69. }
  70. if interceptor == nil {
  71. return srv.(CurlWithResolveServer).CurlWithResolveParam(ctx, in)
  72. }
  73. info := &grpc.UnaryServerInfo{
  74. Server: srv,
  75. FullMethod: CurlWithResolve_CurlWithResolveParam_FullMethodName,
  76. }
  77. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  78. return srv.(CurlWithResolveServer).CurlWithResolveParam(ctx, req.(*CurlRequest))
  79. }
  80. return interceptor(ctx, in, info, handler)
  81. }
  82. // CurlWithResolve_ServiceDesc is the grpc.ServiceDesc for CurlWithResolve service.
  83. // It's only intended for direct use with grpc.RegisterService,
  84. // and not to be introspected or modified (even as a copy)
  85. var CurlWithResolve_ServiceDesc = grpc.ServiceDesc{
  86. ServiceName: "curl.CurlWithResolve",
  87. HandlerType: (*CurlWithResolveServer)(nil),
  88. Methods: []grpc.MethodDesc{
  89. {
  90. MethodName: "CurlWithResolveParam",
  91. Handler: _CurlWithResolve_CurlWithResolveParam_Handler,
  92. },
  93. },
  94. Streams: []grpc.StreamDesc{},
  95. Metadata: "curl.proto",
  96. }