Skip to main content

TransactionViews

Struct TransactionViews 

Source
pub struct TransactionViews<'t> { /* private fields */ }
Expand description

Every transaction view of a message, prepared once.

AssembledTree::transaction_view finds what a view leaves out by walking every other transaction, and the caller then filters the whole message by it: one view costs as much as the message, all of them its square — 1,600 UTILMD transactions took 1.6 s for the views alone. This sorts each segment once into what every view of a kind keeps and what only one transaction’s view keeps, so a view costs its own transaction plus what the transactions share (the header, SG2, …).

Implementations§

Source§

impl TransactionViews<'_>

Source

pub fn view( &self, group_id: &str, index: usize, ) -> Option<TransactionSegmentsView>

Transaction index of the top-level group group_id, as AssembledTree::transaction_view gives it, with the message segments it keeps. None when the group is no transaction group or has no such repetition.

Trait Implementations§

Source§

impl<'t> Debug for TransactionViews<'t>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl<'t> Freeze for TransactionViews<'t>

§

impl<'t> RefUnwindSafe for TransactionViews<'t>

§

impl<'t> Send for TransactionViews<'t>

§

impl<'t> Sync for TransactionViews<'t>

§

impl<'t> Unpin for TransactionViews<'t>

§

impl<'t> UnsafeUnpin for TransactionViews<'t>

§

impl<'t> UnwindSafe for TransactionViews<'t>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.