Struct PrefilledTransaction
pub struct PrefilledTransaction {
pub idx: u16,
pub tx: Transaction,
}
Expand description
A PrefilledTransaction structure is used in HeaderAndShortIds to provide a list of a few transactions explicitly.
Fields§
§idx: u16
The index of the transaction in the block.
This field is differentially encoded relative to the previous prefilled transaction as described as follows:
Several uses of CompactSize below are “differentially encoded”. For these, instead of using raw indexes, the number encoded is the difference between the current index and the previous index, minus one. For example, a first index of 0 implies a real index of 0, a second index of 0 thereafter refers to a real index of 1, etc.
tx: Transaction
The actual transaction.
Trait Implementations§
§impl AsRef<Transaction> for PrefilledTransaction
impl AsRef<Transaction> for PrefilledTransaction
§fn as_ref(&self) -> &Transaction
fn as_ref(&self) -> &Transaction
Converts this type into a shared reference of the (usually inferred) input type.
§impl Clone for PrefilledTransaction
impl Clone for PrefilledTransaction
§fn clone(&self) -> PrefilledTransaction
fn clone(&self) -> PrefilledTransaction
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 more§impl Debug for PrefilledTransaction
impl Debug for PrefilledTransaction
§impl Decodable for PrefilledTransaction
impl Decodable for PrefilledTransaction
§fn consensus_decode<D>(d: &mut D) -> Result<PrefilledTransaction, Error>
fn consensus_decode<D>(d: &mut D) -> Result<PrefilledTransaction, Error>
Decode an object with a well-defined format. Read more
§impl Encodable for PrefilledTransaction
impl Encodable for PrefilledTransaction
§impl Hash for PrefilledTransaction
impl Hash for PrefilledTransaction
§impl Ord for PrefilledTransaction
impl Ord for PrefilledTransaction
§fn cmp(&self, other: &PrefilledTransaction) -> Ordering
fn cmp(&self, other: &PrefilledTransaction) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
§impl PartialEq for PrefilledTransaction
impl PartialEq for PrefilledTransaction
§impl PartialOrd for PrefilledTransaction
impl PartialOrd for PrefilledTransaction
impl Eq for PrefilledTransaction
impl StructuralPartialEq for PrefilledTransaction
Auto Trait Implementations§
impl Freeze for PrefilledTransaction
impl RefUnwindSafe for PrefilledTransaction
impl Send for PrefilledTransaction
impl Sync for PrefilledTransaction
impl Unpin for PrefilledTransaction
impl UnwindSafe for PrefilledTransaction
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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
)§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
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.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> 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>
Wrap the input message
T
in a tonic::Request