...

Source file src/github.com/letsencrypt/boulder/va/proto/va_grpc.pb.go

Documentation: github.com/letsencrypt/boulder/va/proto

     1  // Code generated by protoc-gen-go-grpc. DO NOT EDIT.
     2  // versions:
     3  // - protoc-gen-go-grpc v1.2.0
     4  // - protoc             v3.20.1
     5  // source: va.proto
     6  
     7  package proto
     8  
     9  import (
    10  	context "context"
    11  	grpc "google.golang.org/grpc"
    12  	codes "google.golang.org/grpc/codes"
    13  	status "google.golang.org/grpc/status"
    14  )
    15  
    16  // This is a compile-time assertion to ensure that this generated file
    17  // is compatible with the grpc package it is being compiled against.
    18  // Requires gRPC-Go v1.32.0 or later.
    19  const _ = grpc.SupportPackageIsVersion7
    20  
    21  // VAClient is the client API for VA service.
    22  //
    23  // 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.
    24  type VAClient interface {
    25  	PerformValidation(ctx context.Context, in *PerformValidationRequest, opts ...grpc.CallOption) (*ValidationResult, error)
    26  }
    27  
    28  type vAClient struct {
    29  	cc grpc.ClientConnInterface
    30  }
    31  
    32  func NewVAClient(cc grpc.ClientConnInterface) VAClient {
    33  	return &vAClient{cc}
    34  }
    35  
    36  func (c *vAClient) PerformValidation(ctx context.Context, in *PerformValidationRequest, opts ...grpc.CallOption) (*ValidationResult, error) {
    37  	out := new(ValidationResult)
    38  	err := c.cc.Invoke(ctx, "/va.VA/PerformValidation", in, out, opts...)
    39  	if err != nil {
    40  		return nil, err
    41  	}
    42  	return out, nil
    43  }
    44  
    45  // VAServer is the server API for VA service.
    46  // All implementations must embed UnimplementedVAServer
    47  // for forward compatibility
    48  type VAServer interface {
    49  	PerformValidation(context.Context, *PerformValidationRequest) (*ValidationResult, error)
    50  	mustEmbedUnimplementedVAServer()
    51  }
    52  
    53  // UnimplementedVAServer must be embedded to have forward compatible implementations.
    54  type UnimplementedVAServer struct {
    55  }
    56  
    57  func (UnimplementedVAServer) PerformValidation(context.Context, *PerformValidationRequest) (*ValidationResult, error) {
    58  	return nil, status.Errorf(codes.Unimplemented, "method PerformValidation not implemented")
    59  }
    60  func (UnimplementedVAServer) mustEmbedUnimplementedVAServer() {}
    61  
    62  // UnsafeVAServer may be embedded to opt out of forward compatibility for this service.
    63  // Use of this interface is not recommended, as added methods to VAServer will
    64  // result in compilation errors.
    65  type UnsafeVAServer interface {
    66  	mustEmbedUnimplementedVAServer()
    67  }
    68  
    69  func RegisterVAServer(s grpc.ServiceRegistrar, srv VAServer) {
    70  	s.RegisterService(&VA_ServiceDesc, srv)
    71  }
    72  
    73  func _VA_PerformValidation_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
    74  	in := new(PerformValidationRequest)
    75  	if err := dec(in); err != nil {
    76  		return nil, err
    77  	}
    78  	if interceptor == nil {
    79  		return srv.(VAServer).PerformValidation(ctx, in)
    80  	}
    81  	info := &grpc.UnaryServerInfo{
    82  		Server:     srv,
    83  		FullMethod: "/va.VA/PerformValidation",
    84  	}
    85  	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
    86  		return srv.(VAServer).PerformValidation(ctx, req.(*PerformValidationRequest))
    87  	}
    88  	return interceptor(ctx, in, info, handler)
    89  }
    90  
    91  // VA_ServiceDesc is the grpc.ServiceDesc for VA service.
    92  // It's only intended for direct use with grpc.RegisterService,
    93  // and not to be introspected or modified (even as a copy)
    94  var VA_ServiceDesc = grpc.ServiceDesc{
    95  	ServiceName: "va.VA",
    96  	HandlerType: (*VAServer)(nil),
    97  	Methods: []grpc.MethodDesc{
    98  		{
    99  			MethodName: "PerformValidation",
   100  			Handler:    _VA_PerformValidation_Handler,
   101  		},
   102  	},
   103  	Streams:  []grpc.StreamDesc{},
   104  	Metadata: "va.proto",
   105  }
   106  
   107  // CAAClient is the client API for CAA service.
   108  //
   109  // 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.
   110  type CAAClient interface {
   111  	IsCAAValid(ctx context.Context, in *IsCAAValidRequest, opts ...grpc.CallOption) (*IsCAAValidResponse, error)
   112  }
   113  
   114  type cAAClient struct {
   115  	cc grpc.ClientConnInterface
   116  }
   117  
   118  func NewCAAClient(cc grpc.ClientConnInterface) CAAClient {
   119  	return &cAAClient{cc}
   120  }
   121  
   122  func (c *cAAClient) IsCAAValid(ctx context.Context, in *IsCAAValidRequest, opts ...grpc.CallOption) (*IsCAAValidResponse, error) {
   123  	out := new(IsCAAValidResponse)
   124  	err := c.cc.Invoke(ctx, "/va.CAA/IsCAAValid", in, out, opts...)
   125  	if err != nil {
   126  		return nil, err
   127  	}
   128  	return out, nil
   129  }
   130  
   131  // CAAServer is the server API for CAA service.
   132  // All implementations must embed UnimplementedCAAServer
   133  // for forward compatibility
   134  type CAAServer interface {
   135  	IsCAAValid(context.Context, *IsCAAValidRequest) (*IsCAAValidResponse, error)
   136  	mustEmbedUnimplementedCAAServer()
   137  }
   138  
   139  // UnimplementedCAAServer must be embedded to have forward compatible implementations.
   140  type UnimplementedCAAServer struct {
   141  }
   142  
   143  func (UnimplementedCAAServer) IsCAAValid(context.Context, *IsCAAValidRequest) (*IsCAAValidResponse, error) {
   144  	return nil, status.Errorf(codes.Unimplemented, "method IsCAAValid not implemented")
   145  }
   146  func (UnimplementedCAAServer) mustEmbedUnimplementedCAAServer() {}
   147  
   148  // UnsafeCAAServer may be embedded to opt out of forward compatibility for this service.
   149  // Use of this interface is not recommended, as added methods to CAAServer will
   150  // result in compilation errors.
   151  type UnsafeCAAServer interface {
   152  	mustEmbedUnimplementedCAAServer()
   153  }
   154  
   155  func RegisterCAAServer(s grpc.ServiceRegistrar, srv CAAServer) {
   156  	s.RegisterService(&CAA_ServiceDesc, srv)
   157  }
   158  
   159  func _CAA_IsCAAValid_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
   160  	in := new(IsCAAValidRequest)
   161  	if err := dec(in); err != nil {
   162  		return nil, err
   163  	}
   164  	if interceptor == nil {
   165  		return srv.(CAAServer).IsCAAValid(ctx, in)
   166  	}
   167  	info := &grpc.UnaryServerInfo{
   168  		Server:     srv,
   169  		FullMethod: "/va.CAA/IsCAAValid",
   170  	}
   171  	handler := func(ctx context.Context, req interface{}) (interface{}, error) {
   172  		return srv.(CAAServer).IsCAAValid(ctx, req.(*IsCAAValidRequest))
   173  	}
   174  	return interceptor(ctx, in, info, handler)
   175  }
   176  
   177  // CAA_ServiceDesc is the grpc.ServiceDesc for CAA service.
   178  // It's only intended for direct use with grpc.RegisterService,
   179  // and not to be introspected or modified (even as a copy)
   180  var CAA_ServiceDesc = grpc.ServiceDesc{
   181  	ServiceName: "va.CAA",
   182  	HandlerType: (*CAAServer)(nil),
   183  	Methods: []grpc.MethodDesc{
   184  		{
   185  			MethodName: "IsCAAValid",
   186  			Handler:    _CAA_IsCAAValid_Handler,
   187  		},
   188  	},
   189  	Streams:  []grpc.StreamDesc{},
   190  	Metadata: "va.proto",
   191  }
   192  

View as plain text