pub struct Counterparty {
pub counterparty_type: CounterpartyType,
pub public_key: Option<PublicKey>,
}Expand description
Represents the other party in a cryptographic operation.
Can be a specific public key, or one of the special values “self” or “anyone”.
Serializes as a JSON string: “anyone”, “self”, or DER hex public key, matching the Go SDK encoding.
Fields§
§counterparty_type: CounterpartyType§public_key: Option<PublicKey>Trait Implementations§
Source§impl Clone for Counterparty
impl Clone for Counterparty
Source§fn clone(&self) -> Counterparty
fn clone(&self) -> Counterparty
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for Counterparty
impl Debug for Counterparty
Source§impl Default for Counterparty
impl Default for Counterparty
Source§fn default() -> Self
fn default() -> Self
Default to Uninitialized — the sentinel that ProtoWallet::default_counterparty()
substitutes with the correct per-op default (self for most crypto ops,
anyone for createSignature). Returning a concrete value here would bypass
that per-op dispatch and silently mis-derive keys across SDKs.
Auto Trait Implementations§
impl Freeze for Counterparty
impl !RefUnwindSafe for Counterparty
impl Send for Counterparty
impl Sync for Counterparty
impl Unpin for Counterparty
impl UnsafeUnpin for Counterparty
impl !UnwindSafe for Counterparty
Blanket Implementations§
Source§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
Mutably borrows from an owned value. Read more