Struct sc_transaction_pool::Transaction
source · pub struct Transaction<Hash, Extrinsic> {
pub data: Extrinsic,
pub bytes: usize,
pub hash: Hash,
pub priority: TransactionPriority,
pub valid_till: TransactionLongevity,
pub requires: Vec<TransactionTag>,
pub provides: Vec<TransactionTag>,
pub propagate: bool,
pub source: TransactionSource,
}
Expand description
Immutable transaction
Fields§
§data: Extrinsic
Raw extrinsic representing that transaction.
bytes: usize
Number of bytes encoding of the transaction requires.
hash: Hash
Transaction hash (unique)
priority: TransactionPriority
Transaction priority (higher = better)
valid_till: TransactionLongevity
At which block the transaction becomes invalid?
requires: Vec<TransactionTag>
Tags required by the transaction.
provides: Vec<TransactionTag>
Tags that this transaction provides.
propagate: bool
Should that transaction be propagated.
source: TransactionSource
Source of that transaction.
Implementations§
source§impl<Hash: Clone, Extrinsic: Clone> Transaction<Hash, Extrinsic>
impl<Hash: Clone, Extrinsic: Clone> Transaction<Hash, Extrinsic>
Trait Implementations§
source§impl<Hash, Extrinsic> AsRef<Extrinsic> for Transaction<Hash, Extrinsic>
impl<Hash, Extrinsic> AsRef<Extrinsic> for Transaction<Hash, Extrinsic>
source§fn as_ref(&self) -> &Extrinsic
fn as_ref(&self) -> &Extrinsic
Converts this type into a shared reference of the (usually inferred) input type.
source§impl<Hash: Clone, Extrinsic: Clone> Clone for Transaction<Hash, Extrinsic>
impl<Hash: Clone, Extrinsic: Clone> Clone for Transaction<Hash, Extrinsic>
source§fn clone(&self) -> Transaction<Hash, Extrinsic>
fn clone(&self) -> Transaction<Hash, Extrinsic>
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<Hash, Extrinsic> Debug for Transaction<Hash, Extrinsic>
impl<Hash, Extrinsic> Debug for Transaction<Hash, Extrinsic>
source§impl<Hash, Extrinsic> InPoolTransaction for Transaction<Hash, Extrinsic>
impl<Hash, Extrinsic> InPoolTransaction for Transaction<Hash, Extrinsic>
§type Transaction = Extrinsic
type Transaction = Extrinsic
Transaction type.
source§fn data(&self) -> &Extrinsic
fn data(&self) -> &Extrinsic
Get the reference to the transaction data.
source§fn is_propagable(&self) -> bool
fn is_propagable(&self) -> bool
Return a flag indicating if the transaction should be propagated to other peers.
source§impl<Hash: PartialEq, Extrinsic: PartialEq> PartialEq for Transaction<Hash, Extrinsic>
impl<Hash: PartialEq, Extrinsic: PartialEq> PartialEq for Transaction<Hash, Extrinsic>
source§fn eq(&self, other: &Transaction<Hash, Extrinsic>) -> bool
fn eq(&self, other: &Transaction<Hash, Extrinsic>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl<Hash: Eq, Extrinsic: Eq> Eq for Transaction<Hash, Extrinsic>
impl<Hash, Extrinsic> StructuralPartialEq for Transaction<Hash, Extrinsic>
Auto Trait Implementations§
impl<Hash, Extrinsic> Freeze for Transaction<Hash, Extrinsic>
impl<Hash, Extrinsic> RefUnwindSafe for Transaction<Hash, Extrinsic>where
Extrinsic: RefUnwindSafe,
Hash: RefUnwindSafe,
impl<Hash, Extrinsic> Send for Transaction<Hash, Extrinsic>
impl<Hash, Extrinsic> Sync for Transaction<Hash, Extrinsic>
impl<Hash, Extrinsic> Unpin for Transaction<Hash, Extrinsic>
impl<Hash, Extrinsic> UnwindSafe for Transaction<Hash, Extrinsic>where
Extrinsic: UnwindSafe,
Hash: UnwindSafe,
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> CheckedConversion for T
impl<T> CheckedConversion for T
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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 moresource§impl<T, Outer> IsWrappedBy<Outer> for T
impl<T, Outer> IsWrappedBy<Outer> for T
source§impl<T> Pointable for T
impl<T> Pointable for T
source§impl<T> SaturatedConversion for T
impl<T> SaturatedConversion for T
source§fn saturated_from<T>(t: T) -> Selfwhere
Self: UniqueSaturatedFrom<T>,
fn saturated_from<T>(t: T) -> Selfwhere
Self: UniqueSaturatedFrom<T>,
source§fn saturated_into<T>(self) -> Twhere
Self: UniqueSaturatedInto<T>,
fn saturated_into<T>(self) -> Twhere
Self: UniqueSaturatedInto<T>,
Consume self to return an equivalent value of
T
. Read moresource§impl<S, T> UncheckedInto<T> for Swhere
T: UncheckedFrom<S>,
impl<S, T> UncheckedInto<T> for Swhere
T: UncheckedFrom<S>,
source§fn unchecked_into(self) -> T
fn unchecked_into(self) -> T
The counterpart to
unchecked_from
.source§impl<T, S> UniqueSaturatedInto<T> for S
impl<T, S> UniqueSaturatedInto<T> for S
source§fn unique_saturated_into(self) -> T
fn unique_saturated_into(self) -> T
Consume self to return an equivalent value of
T
.