pub enum SubscriptionKind {
NewHeads,
Logs,
NewPendingTransactions,
Syncing,
}
serde
only.Expand description
Subscription kind.
Variants§
NewHeads
New block headers subscription.
Fires a notification each time a new header is appended to the chain, including chain reorganizations. In case of a chain reorganization the subscription will emit all new headers for the new chain. Therefore the subscription can emit multiple headers on the same height.
Logs
Logs subscription.
Returns logs that are included in new imported blocks and match the given filter criteria. In case of a chain reorganization previous sent logs that are on the old chain will be resent with the removed property set to true. Logs from transactions that ended up in the new chain are emitted. Therefore, a subscription can emit logs for the same transaction multiple times.
NewPendingTransactions
New Pending Transactions subscription.
Returns the hash or full tx for all transactions that are added to the pending state and are signed with a key that is available in the node. When a transaction that was previously part of the canonical chain isn’t part of the new canonical chain after a reorganization its again emitted.
Syncing
Node syncing status subscription.
Indicates when the node starts or stops synchronizing. The result can either be a boolean indicating that the synchronization has started (true), finished (false) or an object with various progress indicators.
Trait Implementations§
source§impl Clone for SubscriptionKind
impl Clone for SubscriptionKind
source§fn clone(&self) -> SubscriptionKind
fn clone(&self) -> SubscriptionKind
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for SubscriptionKind
impl Debug for SubscriptionKind
source§impl<'de> Deserialize<'de> for SubscriptionKind
impl<'de> Deserialize<'de> for SubscriptionKind
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>,
source§impl Hash for SubscriptionKind
impl Hash for SubscriptionKind
source§impl PartialEq for SubscriptionKind
impl PartialEq for SubscriptionKind
source§impl Serialize for SubscriptionKind
impl Serialize for SubscriptionKind
impl Copy for SubscriptionKind
impl Eq for SubscriptionKind
impl StructuralPartialEq for SubscriptionKind
Auto Trait Implementations§
impl Freeze for SubscriptionKind
impl RefUnwindSafe for SubscriptionKind
impl Send for SubscriptionKind
impl Sync for SubscriptionKind
impl Unpin for SubscriptionKind
impl UnwindSafe for SubscriptionKind
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
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)
clone_to_uninit
)source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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>
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>
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 more