pub struct ChainSwapData {Show 22 fields
pub id: String,
pub status: SwapStatus,
pub direction: ChainSwapDirection,
pub preimage: Option<[u8; 32]>,
pub preimage_hash: Hash,
pub claim_public_key: PublicKey,
pub refund_public_key: PublicKey,
pub server_claim_public_key: PublicKey,
pub server_refund_public_key: PublicKey,
pub user_lockup_address: String,
pub server_lockup_address: String,
pub user_lockup_amount: Amount,
pub server_lockup_amount: Amount,
pub user_timeout_block_height: u32,
pub server_timeout_block_height: u32,
pub user_timeout_block_heights: Option<TimeoutBlockHeights>,
pub server_timeout_block_heights: Option<TimeoutBlockHeights>,
pub bip21: Option<String>,
pub swap_tree: Option<SwapTree>,
pub created_at: u64,
pub claim_key_derivation_index: Option<u32>,
pub refund_key_derivation_index: Option<u32>,
}Expand description
Data for a pending chain swap (ARK ↔ BTC).
Fields§
§id: StringUnique swap identifier.
status: SwapStatusCurrent swap status.
direction: ChainSwapDirectionDirection of the swap.
preimage: Option<[u8; 32]>Preimage for the swap.
preimage_hash: HashThe preimage hash.
claim_public_key: PublicKeyUser’s claim public key (for claiming Boltz’s VHTLC).
refund_public_key: PublicKeyUser’s refund public key (for refunding user’s VHTLC).
server_claim_public_key: PublicKeyBoltz’s claim public key (on user’s VHTLC).
server_refund_public_key: PublicKeyBoltz’s refund public key (on Boltz’s VHTLC).
user_lockup_address: StringAddress where user locks funds.
server_lockup_address: StringAddress where Boltz locks funds.
user_lockup_amount: AmountAmount user locks up.
server_lockup_amount: AmountAmount Boltz locks up (what user receives).
user_timeout_block_height: u32Timeout block height for user’s lockup.
server_timeout_block_height: u32Timeout block height for Boltz’s lockup.
user_timeout_block_heights: Option<TimeoutBlockHeights>Full VHTLC timelocks for user’s lockup (present when user locks on ARK side).
server_timeout_block_heights: Option<TimeoutBlockHeights>Full VHTLC timelocks for Boltz’s lockup (present when server locks on ARK side).
bip21: Option<String>BIP21 payment URI for funding (present for on-chain BTC lockup).
swap_tree: Option<SwapTree>Swap tree for the on-chain BTC HTLC (present for the BTC side of chain swaps).
created_at: u64UNIX timestamp when swap was created.
claim_key_derivation_index: Option<u32>BIP32 derivation index for the claim key.
refund_key_derivation_index: Option<u32>BIP32 derivation index for the refund key.
Trait Implementations§
Source§impl Clone for ChainSwapData
impl Clone for ChainSwapData
Source§fn clone(&self) -> ChainSwapData
fn clone(&self) -> ChainSwapData
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ChainSwapData
impl Debug for ChainSwapData
Source§impl<'de> Deserialize<'de> for ChainSwapData
impl<'de> Deserialize<'de> for ChainSwapData
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Auto Trait Implementations§
impl Freeze for ChainSwapData
impl RefUnwindSafe for ChainSwapData
impl Send for ChainSwapData
impl Sync for ChainSwapData
impl Unpin for ChainSwapData
impl UnsafeUnpin for ChainSwapData
impl UnwindSafe for ChainSwapData
Blanket Implementations§
Source§impl<T> AnyExt for T
impl<T> AnyExt for T
Source§fn downcast_ref<T>(this: &Self) -> Option<&T>where
T: Any,
fn downcast_ref<T>(this: &Self) -> Option<&T>where
T: Any,
T behind referenceSource§fn downcast_mut<T>(this: &mut Self) -> Option<&mut T>where
T: Any,
fn downcast_mut<T>(this: &mut Self) -> Option<&mut T>where
T: Any,
T behind mutable referenceSource§fn downcast_rc<T>(this: Rc<Self>) -> Result<Rc<T>, Rc<Self>>where
T: Any,
fn downcast_rc<T>(this: Rc<Self>) -> Result<Rc<T>, Rc<Self>>where
T: Any,
T behind Rc pointerSource§fn downcast_arc<T>(this: Arc<Self>) -> Result<Arc<T>, Arc<Self>>where
T: Any,
fn downcast_arc<T>(this: Arc<Self>) -> Result<Arc<T>, Arc<Self>>where
T: Any,
T behind Arc pointerSource§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T, X> CoerceTo<T> for Xwhere
T: CoerceFrom<X> + ?Sized,
impl<T, X> CoerceTo<T> for Xwhere
T: CoerceFrom<X> + ?Sized,
fn coerce_rc_to(self: Rc<X>) -> Rc<T>
fn coerce_box_to(self: Box<X>) -> Box<T>
fn coerce_ref_to(&self) -> &T
fn coerce_mut_to(&mut self) -> &mut T
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request