pub trait InPoolTransaction {
    type Transaction;
    type Hash;

    // Required methods
    fn data(&self) -> &Self::Transaction;
    fn hash(&self) -> &Self::Hash;
    fn priority(&self) -> &u64;
    fn longevity(&self) -> &u64;
    fn requires(&self) -> &[Vec<u8, Global>];
    fn provides(&self) -> &[Vec<u8, Global>];
    fn is_propagable(&self) -> bool;
}
Expand description

In-pool transaction interface.

The pool is container of transactions that are implementing this trait. See sp_runtime::ValidTransaction for details about every field.

Required Associated Types§

source

type Transaction

Transaction type.

source

type Hash

Transaction hash type.

Required Methods§

source

fn data(&self) -> &Self::Transaction

Get the reference to the transaction data.

source

fn hash(&self) -> &Self::Hash

Get hash of the transaction.

source

fn priority(&self) -> &u64

Get priority of the transaction.

source

fn longevity(&self) -> &u64

Get longevity of the transaction.

source

fn requires(&self) -> &[Vec<u8, Global>]

Get transaction dependencies.

source

fn provides(&self) -> &[Vec<u8, Global>]

Get tags that transaction provides.

source

fn is_propagable(&self) -> bool

Return a flag indicating if the transaction should be propagated to other peers.

Implementations on Foreign Types§

source§

impl<Hash, Extrinsic> InPoolTransaction for Transaction<Hash, Extrinsic>

§

type Transaction = Extrinsic

§

type Hash = Hash

source§

fn data(&self) -> &Extrinsic

source§

fn hash(&self) -> &Hash

source§

fn priority(&self) -> &u64

source§

fn longevity(&self) -> &u64

source§

fn requires(&self) -> &[Vec<u8, Global>]

source§

fn provides(&self) -> &[Vec<u8, Global>]

source§

fn is_propagable(&self) -> bool

Implementors§