pub struct AsyncTransactionStatus { /* private fields */ }Expand description
TransactionStatus object relating to an asynchronous transaction on the network.
Used to query into the status of the Transaction for whether it has completed or not.
Implementations§
source§impl AsyncTransactionStatus
impl AsyncTransactionStatus
sourcepub async fn status(&self) -> Result<Poll<ExecutionFinalResult>>
pub async fn status(&self) -> Result<Poll<ExecutionFinalResult>>
Query the status of the transaction. This will return a [TransactionStatus]
object that we can use to query into the status of the transaction.
sourcepub async fn wait(self, interval: Duration) -> Result<ExecutionFinalResult>
pub async fn wait(self, interval: Duration) -> Result<ExecutionFinalResult>
Wait until the transaction completes with a given time interval. This will poll the
AsyncTransactionStatus::status every interval until the transaction completes.
sourcepub async fn wait_until(
self,
wait_until: TxExecutionStatus,
) -> Result<ExecutionFinalResult>
pub async fn wait_until( self, wait_until: TxExecutionStatus, ) -> Result<ExecutionFinalResult>
Waits until a sepcific transaction status is reached.
sourcepub fn sender_id(&self) -> &AccountId
pub fn sender_id(&self) -> &AccountId
Get the AccountId of the account that initiated this transaction.
sourcepub fn hash(&self) -> &CryptoHash
pub fn hash(&self) -> &CryptoHash
Reference CryptoHash to the submitted transaction, pending completion.
Trait Implementations§
source§impl Clone for AsyncTransactionStatus
impl Clone for AsyncTransactionStatus
source§fn clone(&self) -> AsyncTransactionStatus
fn clone(&self) -> AsyncTransactionStatus
Returns a copy 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 AsyncTransactionStatus
impl Debug for AsyncTransactionStatus
source§impl IntoFuture for AsyncTransactionStatus
impl IntoFuture for AsyncTransactionStatus
source§type Output = Result<ExecutionFinalResult, Error>
type Output = Result<ExecutionFinalResult, Error>
The output that the future will produce on completion.
source§type IntoFuture = Pin<Box<dyn Future<Output = <AsyncTransactionStatus as IntoFuture>::Output> + Send>>
type IntoFuture = Pin<Box<dyn Future<Output = <AsyncTransactionStatus as IntoFuture>::Output> + Send>>
Which kind of future are we turning this into?
source§fn into_future(self) -> Self::IntoFuture
fn into_future(self) -> Self::IntoFuture
Creates a future from a value. Read more
Auto Trait Implementations§
impl Freeze for AsyncTransactionStatus
impl !RefUnwindSafe for AsyncTransactionStatus
impl Send for AsyncTransactionStatus
impl Sync for AsyncTransactionStatus
impl Unpin for AsyncTransactionStatus
impl !UnwindSafe for AsyncTransactionStatus
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit)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> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more