pub struct ZMQNotificationInterface { /* private fields */ }

Implementations§

Trait Implementations§

source§

impl BlockChecked for ZMQNotificationInterface

source§

fn block_checked(self: Arc<Self>, _0: &Block, _1: &BlockValidationState)

| Notifies listeners of a block validation | result. | | If the provided BlockValidationState | IsValid, the provided block is guaranteed | to be the current best block at the time | the callback was generated (not necessarily | now) |
source§

impl BlockConnected for ZMQNotificationInterface

source§

fn block_connected( &mut self, pblock: Arc<Block>, pindex_connected: Arc<BlockIndex> )

| Notifies listeners of a block being | connected. | | Provides a vector of transactions evicted | from the mempool as a result. | | Called on a background thread. |
source§

impl BlockDisconnected for ZMQNotificationInterface

source§

fn block_disconnected( &mut self, pblock: Arc<Block>, pindex_disconnected: Arc<BlockIndex> )

| Notifies listeners of a block being | disconnected | | Called on a background thread. |
source§

impl ChainStateFlushed for ZMQNotificationInterface

source§

fn chain_state_flushed(&mut self, locator: &BlockLocator)

| Notifies listeners of the new active | block chain on-disk. | | Prior to this callback, any updates | are not guaranteed to persist on disk | (ie clients need to handle shutdown/restart | safety by being able to understand when | some updates were lost due to unclean | shutdown). | | When this callback is invoked, the validation | changes done by any prior callback are | guaranteed to exist on disk and survive | a restart, including an unclean shutdown. | | Provides a locator describing the best | chain, which is likely useful for storing | current state on disk in client DBs. | | Called on a background thread. |
source§

impl Default for ZMQNotificationInterface

source§

fn default() -> Self

Returns the “default value” for a type. Read more
source§

impl Drop for ZMQNotificationInterface

source§

fn drop(&mut self)

Executes the destructor for this type. Read more
source§

impl Initialize for ZMQNotificationInterface

source§

fn initialize(&mut self, pcontext: *mut c_void) -> bool

| Called at startup to conditionally | set up ZMQ socket(s) |

source§

impl NewPoWValidBlock for ZMQNotificationInterface

source§

fn new_pow_valid_block(&mut self, pindex: Arc<BlockIndex>, block: &Arc<Block>)

| Notifies listeners that a block which | builds directly on our current tip has | been received and connected to the headers | tree, though not validated yet |
source§

impl Shutdown for ZMQNotificationInterface

source§

fn shutdown(&mut self)

| Called during shutdown sequence |

source§

impl TransactionAddedToMempool for ZMQNotificationInterface

source§

fn transaction_added_to_mempool( &mut self, ptx: &TransactionRef, mempool_sequence: u64 )

| Notifies listeners of a transaction | having been added to mempool. | | Called on a background thread. |
source§

impl TransactionRemovedFromMempool for ZMQNotificationInterface

source§

fn transaction_removed_from_mempool( &mut self, ptx: &TransactionRef, reason: MemPoolRemovalReason, mempool_sequence: u64 )

| Notifies listeners of a transaction | leaving mempool. | | This notification fires for transactions | that are removed from the mempool for | the following reasons: | | - EXPIRY (expired from mempool after | -mempoolexpiry hours) | | - SIZELIMIT (removed in size limiting | if the mempool exceeds -maxmempool | megabytes) | | - REORG (removed during a reorg) | | - CONFLICT (removed because it conflicts | with in-block transaction) | | - REPLACED (removed due to RBF replacement) | | This does not fire for transactions | that are removed from the mempool because | they have been included in a block. Any | client that is interested in transactions | removed from the mempool for inclusion | in a block can learn about those transactions | from the BlockConnected notification. | | Transactions that are removed from | the mempool because they conflict with | a transaction in the new block will have | | TransactionRemovedFromMempool events | fired before the BlockConnected | event is fired. If multiple blocks are | connected in one step, then the ordering | could be: | | - TransactionRemovedFromMempool(tx1 | from block A) | | - TransactionRemovedFromMempool(tx2 | from block A) | | - TransactionRemovedFromMempool(tx1 | from block B) | | - TransactionRemovedFromMempool(tx2 | from block B) | | - BlockConnected(A) | | - BlockConnected(B) | | Called on a background thread. |
source§

impl UpdatedBlockTip for ZMQNotificationInterface

source§

fn updated_block_tip( &mut self, pindex_new: Option<Arc<BlockIndex>>, pindex_fork: Option<Arc<BlockIndex>>, initial_download: bool )

| Notifies listeners when the block chain | tip advances. | | When multiple blocks are connected | at once, UpdatedBlockTip will be called | on the final tip but may not be called | on every intermediate tip. If the latter | behavior is desired, subscribe to BlockConnected() | instead. | | Called on a background thread. |
source§

impl ValidationInterface for ZMQNotificationInterface

Auto Trait Implementations§

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

const: unstable · source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

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

const: unstable · source§

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

Mutably borrows from an owned value. Read more
§

impl<T, U> CastInto<U> for Twhere U: CastFrom<T>,

§

unsafe fn cast_into(self) -> U

Performs the conversion. Read more
source§

impl<T> From<T> for T

const: unstable · source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

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

const: unstable · 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.

§

impl<T> Pointable for T

§

const ALIGN: usize = mem::align_of::<T>()

The alignment of pointer.
§

type Init = T

The type for initializers.
§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
§

impl<T> StaticUpcast<T> for T

§

unsafe fn static_upcast(ptr: Ptr<T>) -> Ptr<T>

Convert type of a const pointer. Read more
source§

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

§

type Error = Infallible

The type returned in the event of a conversion error.
const: unstable · source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

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

§

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

The type returned in the event of a conversion error.
const: unstable · source§

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

Performs the conversion.
§

impl<V, T> VZip<V> for Twhere V: MultiLane<T>,

§

fn vzip(self) -> V