Struct SparkServiceClient

Source
pub struct SparkServiceClient<T> { /* private fields */ }

Implementations§

Source§

impl SparkServiceClient<Channel>

Source

pub async fn connect<D>(dst: D) -> Result<Self, Error>
where D: TryInto<Endpoint>, D::Error: Into<StdError>,

Attempt to create a new client by connecting to a given endpoint.

Source§

impl<T> SparkServiceClient<T>
where T: GrpcService<BoxBody>, T::Error: Into<StdError>, T::ResponseBody: Body<Data = Bytes> + Send + 'static, <T::ResponseBody as Body>::Error: Into<StdError> + Send,

Source

pub fn new(inner: T) -> Self

Source

pub fn with_origin(inner: T, origin: Uri) -> Self

Source

pub fn with_interceptor<F>( inner: T, interceptor: F, ) -> SparkServiceClient<InterceptedService<T, F>>
where F: Interceptor, T::ResponseBody: Default, T: Service<Request<BoxBody>, Response = Response<<T as GrpcService<BoxBody>>::ResponseBody>>, <T as Service<Request<BoxBody>>>::Error: Into<StdError> + Send + Sync,

Source

pub fn send_compressed(self, encoding: CompressionEncoding) -> Self

Compress requests with the given encoding.

This requires the server to support it otherwise it might respond with an error.

Source

pub fn accept_compressed(self, encoding: CompressionEncoding) -> Self

Enable decompressing responses.

Source

pub fn max_decoding_message_size(self, limit: usize) -> Self

Limits the maximum size of a decoded message.

Default: 4MB

Source

pub fn max_encoding_message_size(self, limit: usize) -> Self

Limits the maximum size of an encoded message.

Default: usize::MAX

Source

pub async fn generate_deposit_address( &mut self, request: impl IntoRequest<GenerateDepositAddressRequest>, ) -> Result<Response<GenerateDepositAddressResponse>, Status>

Source

pub async fn start_tree_creation( &mut self, request: impl IntoRequest<StartTreeCreationRequest>, ) -> Result<Response<StartTreeCreationResponse>, Status>

Source

pub async fn finalize_node_signatures( &mut self, request: impl IntoRequest<FinalizeNodeSignaturesRequest>, ) -> Result<Response<FinalizeNodeSignaturesResponse>, Status>

Source

pub async fn start_send_transfer( &mut self, request: impl IntoRequest<StartSendTransferRequest>, ) -> Result<Response<StartSendTransferResponse>, Status>

Source

pub async fn complete_send_transfer( &mut self, request: impl IntoRequest<CompleteSendTransferRequest>, ) -> Result<Response<CompleteSendTransferResponse>, Status>

Source

pub async fn query_pending_transfers( &mut self, request: impl IntoRequest<QueryPendingTransfersRequest>, ) -> Result<Response<QueryPendingTransfersResponse>, Status>

Source

pub async fn query_all_transfers( &mut self, request: impl IntoRequest<QueryAllTransfersRequest>, ) -> Result<Response<QueryAllTransfersResponse>, Status>

Source

pub async fn claim_transfer_tweak_keys( &mut self, request: impl IntoRequest<ClaimTransferTweakKeysRequest>, ) -> Result<Response<()>, Status>

Source

pub async fn claim_transfer_sign_refunds( &mut self, request: impl IntoRequest<ClaimTransferSignRefundsRequest>, ) -> Result<Response<ClaimTransferSignRefundsResponse>, Status>

Source

pub async fn aggregate_nodes( &mut self, request: impl IntoRequest<AggregateNodesRequest>, ) -> Result<Response<AggregateNodesResponse>, Status>

Source

pub async fn store_preimage_share( &mut self, request: impl IntoRequest<StorePreimageShareRequest>, ) -> Result<Response<()>, Status>

Source

pub async fn get_signing_commitments( &mut self, request: impl IntoRequest<GetSigningCommitmentsRequest>, ) -> Result<Response<GetSigningCommitmentsResponse>, Status>

Source

pub async fn cooperative_exit( &mut self, request: impl IntoRequest<CooperativeExitRequest>, ) -> Result<Response<CooperativeExitResponse>, Status>

Source

pub async fn initiate_preimage_swap( &mut self, request: impl IntoRequest<InitiatePreimageSwapRequest>, ) -> Result<Response<InitiatePreimageSwapResponse>, Status>

Source

pub async fn provide_preimage( &mut self, request: impl IntoRequest<ProvidePreimageRequest>, ) -> Result<Response<ProvidePreimageResponse>, Status>

Source

pub async fn start_leaf_swap( &mut self, request: impl IntoRequest<StartSendTransferRequest>, ) -> Result<Response<StartSendTransferResponse>, Status>

This is the exact same as start_send_transfer, but expresses to the SO this transfer is specifically for a leaf swap.

Source

pub async fn leaf_swap( &mut self, request: impl IntoRequest<CounterLeafSwapRequest>, ) -> Result<Response<CounterLeafSwapResponse>, Status>

👎Deprecated

This is deprecated, please use counter_leaf_swap instead.

Source

pub async fn counter_leaf_swap( &mut self, request: impl IntoRequest<CounterLeafSwapRequest>, ) -> Result<Response<CounterLeafSwapResponse>, Status>

This is the exact same as start_leaf_swap, but signs with an adaptor public key after a counterparty has begun the swap via start_leaf_swap.

Source

pub async fn refresh_timelock( &mut self, request: impl IntoRequest<RefreshTimelockRequest>, ) -> Result<Response<RefreshTimelockResponse>, Status>

Source

pub async fn extend_leaf( &mut self, request: impl IntoRequest<ExtendLeafRequest>, ) -> Result<Response<ExtendLeafResponse>, Status>

Source

pub async fn prepare_tree_address( &mut self, request: impl IntoRequest<PrepareTreeAddressRequest>, ) -> Result<Response<PrepareTreeAddressResponse>, Status>

Source

pub async fn create_tree( &mut self, request: impl IntoRequest<CreateTreeRequest>, ) -> Result<Response<CreateTreeResponse>, Status>

Source

pub async fn get_signing_operator_list( &mut self, request: impl IntoRequest<()>, ) -> Result<Response<GetSigningOperatorListResponse>, Status>

Source

pub async fn query_nodes( &mut self, request: impl IntoRequest<QueryNodesRequest>, ) -> Result<Response<QueryNodesResponse>, Status>

Source

pub async fn query_balance( &mut self, request: impl IntoRequest<QueryBalanceRequest>, ) -> Result<Response<QueryBalanceResponse>, Status>

Source

pub async fn query_user_signed_refunds( &mut self, request: impl IntoRequest<QueryUserSignedRefundsRequest>, ) -> Result<Response<QueryUserSignedRefundsResponse>, Status>

Source

pub async fn start_token_transaction( &mut self, request: impl IntoRequest<StartTokenTransactionRequest>, ) -> Result<Response<StartTokenTransactionResponse>, Status>

Token RPCs

Source

pub async fn sign_token_transaction( &mut self, request: impl IntoRequest<SignTokenTransactionRequest>, ) -> Result<Response<SignTokenTransactionResponse>, Status>

Source

pub async fn finalize_token_transaction( &mut self, request: impl IntoRequest<FinalizeTokenTransactionRequest>, ) -> Result<Response<()>, Status>

Source

pub async fn freeze_tokens( &mut self, request: impl IntoRequest<FreezeTokensRequest>, ) -> Result<Response<FreezeTokensResponse>, Status>

Source

pub async fn get_owned_token_leaves( &mut self, request: impl IntoRequest<GetOwnedTokenLeavesRequest>, ) -> Result<Response<GetOwnedTokenLeavesResponse>, Status>

Source

pub async fn query_token_transactions( &mut self, request: impl IntoRequest<QueryTokenTransactionsRequest>, ) -> Result<Response<QueryTokenTransactionsResponse>, Status>

Source

pub async fn cancel_signed_token_transaction( &mut self, request: impl IntoRequest<CancelSignedTokenTransactionRequest>, ) -> Result<Response<()>, Status>

Source

pub async fn return_lightning_payment( &mut self, request: impl IntoRequest<ReturnLightningPaymentRequest>, ) -> Result<Response<()>, Status>

Source

pub async fn cancel_send_transfer( &mut self, request: impl IntoRequest<CancelSendTransferRequest>, ) -> Result<Response<CancelSendTransferResponse>, Status>

Source

pub async fn query_unused_deposit_addresses( &mut self, request: impl IntoRequest<QueryUnusedDepositAddressesRequest>, ) -> Result<Response<QueryUnusedDepositAddressesResponse>, Status>

Trait Implementations§

Source§

impl<T: Clone> Clone for SparkServiceClient<T>

Source§

fn clone(&self) -> SparkServiceClient<T>

Returns a copy of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<T: Debug> Debug for SparkServiceClient<T>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl<T> !Freeze for SparkServiceClient<T>

§

impl<T> RefUnwindSafe for SparkServiceClient<T>
where T: RefUnwindSafe,

§

impl<T> Send for SparkServiceClient<T>
where T: Send,

§

impl<T> Sync for SparkServiceClient<T>
where T: Sync,

§

impl<T> Unpin for SparkServiceClient<T>
where T: Unpin,

§

impl<T> UnwindSafe for SparkServiceClient<T>
where T: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> FromRef<T> for T
where T: Clone,

Source§

fn from_ref(input: &T) -> T

Converts to this type from a reference to the input type.
Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoRequest<T> for T

Source§

fn into_request(self) -> Request<T>

Wrap the input message T in a tonic::Request
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more