// Code generated by protoc-gen-go-grpc. DO NOT EDIT. package swapserverrpc import ( context "context" 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 // StaticAddressServerClient is the client API for StaticAddressServer 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 StaticAddressServerClient interface { // ServerNewAddress generates a new static address for the client to use. // The server will generate the address and return the server key and the // address's CSV expiry. ServerNewAddress(ctx context.Context, in *ServerNewAddressRequest, opts ...grpc.CallOption) (*ServerNewAddressResponse, error) // Deprecated: Do not use. // ServerWithdrawDeposits allows to cooperatively sweep deposits that // haven't timed out yet to the client's wallet. The server will generate // the partial sigs for the client's selected deposits. // // Deprecated: use ServerPsbtWithdrawDeposits instead. ServerWithdrawDeposits(ctx context.Context, in *ServerWithdrawRequest, opts ...grpc.CallOption) (*ServerWithdrawResponse, error) // ServerPsbtWithdrawDeposits allows to cooperatively sweep deposits that // haven't timed out yet to the client's wallet. In contrast to // ServerWithdrawDeposits which provides the paramters to form the // withdrawal transaction, this service method will provide a psbt which // is signed by the server. ServerPsbtWithdrawDeposits(ctx context.Context, in *ServerPsbtWithdrawRequest, opts ...grpc.CallOption) (*ServerPsbtWithdrawResponse, error) // ServerStaticAddressLoopIn initiates a static address loop-in swap. The // server will respond with htlc details that the client can use to // construct and sign the htlc tx. ServerStaticAddressLoopIn(ctx context.Context, in *ServerStaticAddressLoopInRequest, opts ...grpc.CallOption) (*ServerStaticAddressLoopInResponse, error) // PushStaticAddressHtlcSigs pushes the client's htlc tx sigs to the server. PushStaticAddressHtlcSigs(ctx context.Context, in *PushStaticAddressHtlcSigsRequest, opts ...grpc.CallOption) (*PushStaticAddressHtlcSigsResponse, error) // PushStaticAddressSweeplessSigs pushes the client's sweepless sweep tx // sigs to the server. PushStaticAddressSweeplessSigs(ctx context.Context, in *PushStaticAddressSweeplessSigsRequest, opts ...grpc.CallOption) (*PushStaticAddressSweeplessSigsResponse, error) } type staticAddressServerClient struct { cc grpc.ClientConnInterface } func NewStaticAddressServerClient(cc grpc.ClientConnInterface) StaticAddressServerClient { return &staticAddressServerClient{cc} } func (c *staticAddressServerClient) ServerNewAddress(ctx context.Context, in *ServerNewAddressRequest, opts ...grpc.CallOption) (*ServerNewAddressResponse, error) { out := new(ServerNewAddressResponse) err := c.cc.Invoke(ctx, "/looprpc.StaticAddressServer/ServerNewAddress", in, out, opts...) if err != nil { return nil, err } return out, nil } // Deprecated: Do not use. func (c *staticAddressServerClient) ServerWithdrawDeposits(ctx context.Context, in *ServerWithdrawRequest, opts ...grpc.CallOption) (*ServerWithdrawResponse, error) { out := new(ServerWithdrawResponse) err := c.cc.Invoke(ctx, "/looprpc.StaticAddressServer/ServerWithdrawDeposits", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *staticAddressServerClient) ServerPsbtWithdrawDeposits(ctx context.Context, in *ServerPsbtWithdrawRequest, opts ...grpc.CallOption) (*ServerPsbtWithdrawResponse, error) { out := new(ServerPsbtWithdrawResponse) err := c.cc.Invoke(ctx, "/looprpc.StaticAddressServer/ServerPsbtWithdrawDeposits", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *staticAddressServerClient) ServerStaticAddressLoopIn(ctx context.Context, in *ServerStaticAddressLoopInRequest, opts ...grpc.CallOption) (*ServerStaticAddressLoopInResponse, error) { out := new(ServerStaticAddressLoopInResponse) err := c.cc.Invoke(ctx, "/looprpc.StaticAddressServer/ServerStaticAddressLoopIn", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *staticAddressServerClient) PushStaticAddressHtlcSigs(ctx context.Context, in *PushStaticAddressHtlcSigsRequest, opts ...grpc.CallOption) (*PushStaticAddressHtlcSigsResponse, error) { out := new(PushStaticAddressHtlcSigsResponse) err := c.cc.Invoke(ctx, "/looprpc.StaticAddressServer/PushStaticAddressHtlcSigs", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *staticAddressServerClient) PushStaticAddressSweeplessSigs(ctx context.Context, in *PushStaticAddressSweeplessSigsRequest, opts ...grpc.CallOption) (*PushStaticAddressSweeplessSigsResponse, error) { out := new(PushStaticAddressSweeplessSigsResponse) err := c.cc.Invoke(ctx, "/looprpc.StaticAddressServer/PushStaticAddressSweeplessSigs", in, out, opts...) if err != nil { return nil, err } return out, nil } // StaticAddressServerServer is the server API for StaticAddressServer service. // All implementations must embed UnimplementedStaticAddressServerServer // for forward compatibility type StaticAddressServerServer interface { // ServerNewAddress generates a new static address for the client to use. // The server will generate the address and return the server key and the // address's CSV expiry. ServerNewAddress(context.Context, *ServerNewAddressRequest) (*ServerNewAddressResponse, error) // Deprecated: Do not use. // ServerWithdrawDeposits allows to cooperatively sweep deposits that // haven't timed out yet to the client's wallet. The server will generate // the partial sigs for the client's selected deposits. // // Deprecated: use ServerPsbtWithdrawDeposits instead. ServerWithdrawDeposits(context.Context, *ServerWithdrawRequest) (*ServerWithdrawResponse, error) // ServerPsbtWithdrawDeposits allows to cooperatively sweep deposits that // haven't timed out yet to the client's wallet. In contrast to // ServerWithdrawDeposits which provides the paramters to form the // withdrawal transaction, this service method will provide a psbt which // is signed by the server. ServerPsbtWithdrawDeposits(context.Context, *ServerPsbtWithdrawRequest) (*ServerPsbtWithdrawResponse, error) // ServerStaticAddressLoopIn initiates a static address loop-in swap. The // server will respond with htlc details that the client can use to // construct and sign the htlc tx. ServerStaticAddressLoopIn(context.Context, *ServerStaticAddressLoopInRequest) (*ServerStaticAddressLoopInResponse, error) // PushStaticAddressHtlcSigs pushes the client's htlc tx sigs to the server. PushStaticAddressHtlcSigs(context.Context, *PushStaticAddressHtlcSigsRequest) (*PushStaticAddressHtlcSigsResponse, error) // PushStaticAddressSweeplessSigs pushes the client's sweepless sweep tx // sigs to the server. PushStaticAddressSweeplessSigs(context.Context, *PushStaticAddressSweeplessSigsRequest) (*PushStaticAddressSweeplessSigsResponse, error) mustEmbedUnimplementedStaticAddressServerServer() } // UnimplementedStaticAddressServerServer must be embedded to have forward compatible implementations. type UnimplementedStaticAddressServerServer struct { } func (UnimplementedStaticAddressServerServer) ServerNewAddress(context.Context, *ServerNewAddressRequest) (*ServerNewAddressResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ServerNewAddress not implemented") } func (UnimplementedStaticAddressServerServer) ServerWithdrawDeposits(context.Context, *ServerWithdrawRequest) (*ServerWithdrawResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ServerWithdrawDeposits not implemented") } func (UnimplementedStaticAddressServerServer) ServerPsbtWithdrawDeposits(context.Context, *ServerPsbtWithdrawRequest) (*ServerPsbtWithdrawResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ServerPsbtWithdrawDeposits not implemented") } func (UnimplementedStaticAddressServerServer) ServerStaticAddressLoopIn(context.Context, *ServerStaticAddressLoopInRequest) (*ServerStaticAddressLoopInResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ServerStaticAddressLoopIn not implemented") } func (UnimplementedStaticAddressServerServer) PushStaticAddressHtlcSigs(context.Context, *PushStaticAddressHtlcSigsRequest) (*PushStaticAddressHtlcSigsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method PushStaticAddressHtlcSigs not implemented") } func (UnimplementedStaticAddressServerServer) PushStaticAddressSweeplessSigs(context.Context, *PushStaticAddressSweeplessSigsRequest) (*PushStaticAddressSweeplessSigsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method PushStaticAddressSweeplessSigs not implemented") } func (UnimplementedStaticAddressServerServer) mustEmbedUnimplementedStaticAddressServerServer() {} // UnsafeStaticAddressServerServer may be embedded to opt out of forward compatibility for this service. // Use of this interface is not recommended, as added methods to StaticAddressServerServer will // result in compilation errors. type UnsafeStaticAddressServerServer interface { mustEmbedUnimplementedStaticAddressServerServer() } func RegisterStaticAddressServerServer(s grpc.ServiceRegistrar, srv StaticAddressServerServer) { s.RegisterService(&StaticAddressServer_ServiceDesc, srv) } func _StaticAddressServer_ServerNewAddress_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(ServerNewAddressRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(StaticAddressServerServer).ServerNewAddress(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/looprpc.StaticAddressServer/ServerNewAddress", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(StaticAddressServerServer).ServerNewAddress(ctx, req.(*ServerNewAddressRequest)) } return interceptor(ctx, in, info, handler) } func _StaticAddressServer_ServerWithdrawDeposits_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(ServerWithdrawRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(StaticAddressServerServer).ServerWithdrawDeposits(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/looprpc.StaticAddressServer/ServerWithdrawDeposits", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(StaticAddressServerServer).ServerWithdrawDeposits(ctx, req.(*ServerWithdrawRequest)) } return interceptor(ctx, in, info, handler) } func _StaticAddressServer_ServerPsbtWithdrawDeposits_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(ServerPsbtWithdrawRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(StaticAddressServerServer).ServerPsbtWithdrawDeposits(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/looprpc.StaticAddressServer/ServerPsbtWithdrawDeposits", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(StaticAddressServerServer).ServerPsbtWithdrawDeposits(ctx, req.(*ServerPsbtWithdrawRequest)) } return interceptor(ctx, in, info, handler) } func _StaticAddressServer_ServerStaticAddressLoopIn_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(ServerStaticAddressLoopInRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(StaticAddressServerServer).ServerStaticAddressLoopIn(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/looprpc.StaticAddressServer/ServerStaticAddressLoopIn", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(StaticAddressServerServer).ServerStaticAddressLoopIn(ctx, req.(*ServerStaticAddressLoopInRequest)) } return interceptor(ctx, in, info, handler) } func _StaticAddressServer_PushStaticAddressHtlcSigs_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(PushStaticAddressHtlcSigsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(StaticAddressServerServer).PushStaticAddressHtlcSigs(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/looprpc.StaticAddressServer/PushStaticAddressHtlcSigs", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(StaticAddressServerServer).PushStaticAddressHtlcSigs(ctx, req.(*PushStaticAddressHtlcSigsRequest)) } return interceptor(ctx, in, info, handler) } func _StaticAddressServer_PushStaticAddressSweeplessSigs_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(PushStaticAddressSweeplessSigsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(StaticAddressServerServer).PushStaticAddressSweeplessSigs(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/looprpc.StaticAddressServer/PushStaticAddressSweeplessSigs", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(StaticAddressServerServer).PushStaticAddressSweeplessSigs(ctx, req.(*PushStaticAddressSweeplessSigsRequest)) } return interceptor(ctx, in, info, handler) } // StaticAddressServer_ServiceDesc is the grpc.ServiceDesc for StaticAddressServer service. // It's only intended for direct use with grpc.RegisterService, // and not to be introspected or modified (even as a copy) var StaticAddressServer_ServiceDesc = grpc.ServiceDesc{ ServiceName: "looprpc.StaticAddressServer", HandlerType: (*StaticAddressServerServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "ServerNewAddress", Handler: _StaticAddressServer_ServerNewAddress_Handler, }, { MethodName: "ServerWithdrawDeposits", Handler: _StaticAddressServer_ServerWithdrawDeposits_Handler, }, { MethodName: "ServerPsbtWithdrawDeposits", Handler: _StaticAddressServer_ServerPsbtWithdrawDeposits_Handler, }, { MethodName: "ServerStaticAddressLoopIn", Handler: _StaticAddressServer_ServerStaticAddressLoopIn_Handler, }, { MethodName: "PushStaticAddressHtlcSigs", Handler: _StaticAddressServer_PushStaticAddressHtlcSigs_Handler, }, { MethodName: "PushStaticAddressSweeplessSigs", Handler: _StaticAddressServer_PushStaticAddressSweeplessSigs_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "staticaddr.proto", }