Struct cfx_rpc_eth_types::TxpoolContent
source · pub struct TxpoolContent<T = Transaction> {
pub pending: BTreeMap<Address, BTreeMap<String, T>>,
pub queued: BTreeMap<Address, BTreeMap<String, T>>,
}
Fields§
§pending: BTreeMap<Address, BTreeMap<String, T>>
pending tx
queued: BTreeMap<Address, BTreeMap<String, T>>
queued tx
Implementations§
source§impl<T> TxpoolContent<T>
impl<T> TxpoolContent<T>
sourcepub fn remove_from(&mut self, sender: &Address) -> TxpoolContentFrom<T>
pub fn remove_from(&mut self, sender: &Address) -> TxpoolContentFrom<T>
Removes the transactions from the given sender
sourcepub fn pending_transactions(&self) -> impl Iterator<Item = &T>
pub fn pending_transactions(&self) -> impl Iterator<Item = &T>
Returns an iterator over references to all pending transactions
sourcepub fn queued_transactions(&self) -> impl Iterator<Item = &T>
pub fn queued_transactions(&self) -> impl Iterator<Item = &T>
Returns an iterator over references to all queued transactions
sourcepub fn pending_transactions_from(
&self,
sender: &Address
) -> impl Iterator<Item = &T>
pub fn pending_transactions_from( &self, sender: &Address ) -> impl Iterator<Item = &T>
Returns an iterator over references to all pending transactions from a specific sender
sourcepub fn queued_transactions_from(
&self,
sender: &Address
) -> impl Iterator<Item = &T>
pub fn queued_transactions_from( &self, sender: &Address ) -> impl Iterator<Item = &T>
Returns an iterator over references to all queued transactions from a specific sender
source§impl<T> TxpoolContent<T>
impl<T> TxpoolContent<T>
sourcepub fn into_pending_transactions(self) -> impl Iterator<Item = T>
pub fn into_pending_transactions(self) -> impl Iterator<Item = T>
Returns an iterator that consumes and yields all pending transactions
sourcepub fn into_queued_transactions(self) -> impl Iterator<Item = T>
pub fn into_queued_transactions(self) -> impl Iterator<Item = T>
Returns an iterator that consumes and yields all queued transactions
sourcepub fn into_pending_transactions_from(
self,
sender: &Address
) -> impl Iterator<Item = T>
pub fn into_pending_transactions_from( self, sender: &Address ) -> impl Iterator<Item = T>
Returns an iterator that consumes and yields all pending transactions from a specific sender
sourcepub fn into_queued_transactions_from(
self,
sender: &Address
) -> impl Iterator<Item = T>
pub fn into_queued_transactions_from( self, sender: &Address ) -> impl Iterator<Item = T>
Returns an iterator that consumes and yields all queued transactions from a specific sender
Trait Implementations§
source§impl<T: Clone> Clone for TxpoolContent<T>
impl<T: Clone> Clone for TxpoolContent<T>
source§fn clone(&self) -> TxpoolContent<T>
fn clone(&self) -> TxpoolContent<T>
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<T: Debug> Debug for TxpoolContent<T>
impl<T: Debug> Debug for TxpoolContent<T>
source§impl<T> Default for TxpoolContent<T>
impl<T> Default for TxpoolContent<T>
source§impl<'de, T> Deserialize<'de> for TxpoolContent<T>where
T: Deserialize<'de>,
impl<'de, T> Deserialize<'de> for TxpoolContent<T>where
T: Deserialize<'de>,
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl<T: PartialEq> PartialEq for TxpoolContent<T>
impl<T: PartialEq> PartialEq for TxpoolContent<T>
source§fn eq(&self, other: &TxpoolContent<T>) -> bool
fn eq(&self, other: &TxpoolContent<T>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl<T> Serialize for TxpoolContent<T>where
T: Serialize,
impl<T> Serialize for TxpoolContent<T>where
T: Serialize,
impl<T: Eq> Eq for TxpoolContent<T>
impl<T> StructuralPartialEq for TxpoolContent<T>
Auto Trait Implementations§
impl<T> RefUnwindSafe for TxpoolContent<T>where
T: RefUnwindSafe,
impl<T> Send for TxpoolContent<T>where
T: Send,
impl<T> Sync for TxpoolContent<T>where
T: Sync,
impl<T> Unpin for TxpoolContent<T>
impl<T> UnwindSafe for TxpoolContent<T>where
T: RefUnwindSafe,
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
§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.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.