Skip to main content

EventPayload

Enum EventPayload 

Source
pub enum EventPayload {
Show 117 variants NewBlock { block_hash: [u8; 32], height: u64, }, NewTransaction { tx_hash: [u8; 32], }, BlockDisconnected { hash: [u8; 32], height: u64, }, ChainReorg { old_tip: [u8; 32], new_tip: [u8; 32], }, PaymentRequestCreated { payment_id: String, amount_sats: u64, invoice: Option<String>, }, PaymentSettled { payment_id: String, tx_hash: [u8; 32], confirmations: u32, }, PaymentFailed { payment_id: String, reason: String, }, PaymentVerified { payment_id: String, amount_msats: u64, invoice: String, }, PaymentRouteFound { payment_id: String, route_hops: usize, route_cost_msats: u64, }, PaymentRouteFailed { payment_id: String, reason: String, }, ChannelOpened { channel_id: String, peer_pubkey: Vec<u8>, capacity_sats: u64, }, ChannelClosed { channel_id: String, reason: String, }, BlockMined { block_hash: [u8; 32], height: u64, miner_id: Option<String>, }, BlockTemplateUpdated { prev_hash: [u8; 32], height: u64, tx_count: usize, }, MiningDifficultyChanged { old_difficulty: u32, new_difficulty: u32, height: u64, }, MiningJobCreated { job_id: String, prev_hash: [u8; 32], height: u64, }, ShareSubmitted { job_id: String, share_hash: [u8; 32], miner_id: Option<String>, }, MergeMiningReward { secondary_chain: String, reward_amount: u64, block_hash: [u8; 32], }, MiningPoolConnected { pool_url: String, pool_id: Option<String>, }, MiningPoolDisconnected { pool_url: String, reason: String, }, GovernanceProposalCreated { proposal_id: String, repository: String, pr_number: u64, tier: String, }, GovernanceProposalVoted { proposal_id: String, voter: String, vote: String, }, GovernanceProposalMerged { proposal_id: String, repository: String, pr_number: u64, }, WebhookSent { webhook_url: String, event_type: String, success: bool, }, WebhookFailed { webhook_url: String, event_type: String, error: String, }, GovernanceForkDetected { fork_id: String, ruleset_version: String, adoption_count: usize, }, PeerConnected { peer_addr: String, transport_type: String, services: u64, version: u32, }, PeerDisconnected { peer_addr: String, reason: String, }, PeerBanned { peer_addr: String, reason: String, ban_duration_seconds: u64, }, PeerUnbanned { peer_addr: String, }, MessageReceived { peer_addr: String, message_type: String, message_size: usize, protocol_version: u32, }, MessageSent { peer_addr: String, message_type: String, message_size: usize, }, BroadcastStarted { message_type: String, target_peers: usize, }, BroadcastCompleted { message_type: String, successful: usize, failed: usize, }, RouteDiscovered { destination: Vec<u8>, route_path: Vec<String>, route_cost: u64, }, RouteFailed { destination: Vec<u8>, reason: String, }, ConnectionAttempt { peer_addr: String, success: bool, error: Option<String>, }, AddressDiscovered { peer_addr: String, source: String, }, AddressExpired { peer_addr: String, }, NetworkPartition { partition_id: Vec<u8>, disconnected_peers: Vec<String>, partition_size: usize, }, NetworkReconnected { partition_id: Vec<u8>, reconnected_peers: Vec<String>, }, DoSAttackDetected { peer_addr: String, attack_type: String, severity: String, }, RateLimitExceeded { peer_addr: String, limit_type: String, current_rate: f64, limit: f64, }, BlockValidationStarted { block_hash: [u8; 32], height: u64, }, BlockValidationCompleted { block_hash: [u8; 32], height: u64, success: bool, validation_time_ms: u64, error: Option<String>, }, ScriptVerificationStarted { tx_hash: [u8; 32], input_index: usize, }, ScriptVerificationCompleted { tx_hash: [u8; 32], input_index: usize, success: bool, verification_time_ms: u64, }, UTXOValidationStarted { block_hash: [u8; 32], height: u64, }, UTXOValidationCompleted { block_hash: [u8; 32], height: u64, success: bool, }, DifficultyAdjusted { old_difficulty: u32, new_difficulty: u32, height: u64, }, SoftForkActivated { fork_name: String, height: u64, }, SoftForkLockedIn { fork_name: String, height: u64, }, ConsensusRuleViolation { rule_name: String, block_hash: Option<[u8; 32]>, tx_hash: Option<[u8; 32]>, error: String, }, HeadersSyncStarted { start_height: u64, }, HeadersSyncProgress { current_height: u64, target_height: u64, progress_percent: f64, }, HeadersSyncCompleted { final_height: u64, duration_seconds: u64, }, BlockSyncStarted { start_height: u64, target_height: u64, }, BlockSyncProgress { current_height: u64, target_height: u64, progress_percent: f64, blocks_per_second: f64, }, BlockSyncCompleted { final_height: u64, duration_seconds: u64, }, SyncStateChanged { old_state: String, new_state: String, }, MempoolTransactionAdded { tx_hash: [u8; 32], fee_rate: f64, mempool_size: usize, }, MempoolTransactionRemoved { tx_hash: [u8; 32], reason: String, mempool_size: usize, }, MempoolThresholdExceeded { current_size: usize, threshold: usize, }, FeeRateChanged { old_fee_rate: f64, new_fee_rate: f64, mempool_size: usize, }, MempoolCleared { cleared_count: usize, }, StorageRead { operation: String, duration_ms: u64, }, StorageWrite { operation: String, duration_ms: u64, bytes_written: usize, }, StorageQuery { query_type: String, duration_ms: u64, }, DatabaseBackupStarted { backup_path: String, }, DatabaseBackupCompleted { backup_path: String, success: bool, size_bytes: u64, duration_seconds: u64, }, ModuleLoaded { module_name: String, version: String, }, ModuleUnloaded { module_name: String, version: String, }, ModuleReloaded { module_name: String, old_version: String, new_version: String, }, ModuleStarted { module_name: String, }, ModuleStopped { module_name: String, }, MeshPacketReceived { packet_data: Vec<u8>, peer_addr: String, }, StratumV2MessageReceived { message_data: Vec<u8>, peer_addr: String, }, ModuleCrashed { module_name: String, error: String, }, ModuleHealthChanged { module_name: String, old_health: String, new_health: String, }, ModuleStateChanged { module_name: String, old_state: String, new_state: String, }, ConfigLoaded { changed_sections: Vec<String>, config_json: Option<String>, }, NodeShutdown { reason: String, timeout_seconds: u64, }, NodeShutdownCompleted { duration_ms: u64, }, NodeStartupCompleted { duration_ms: u64, components: Vec<String>, }, MaintenanceStarted { maintenance_type: String, estimated_duration_seconds: Option<u64>, }, MaintenanceCompleted { maintenance_type: String, success: bool, duration_ms: u64, results: Option<String>, }, DataMaintenance { operation: String, urgency: String, reason: String, target_age_days: Option<u64>, timeout_seconds: Option<u64>, }, HealthCheck { check_type: String, node_healthy: bool, health_report: Option<String>, }, DiskSpaceLow { available_bytes: u64, total_bytes: u64, percent_free: f64, disk_path: String, }, ResourceLimitWarning { resource_type: String, usage_percent: f64, current_usage: u64, limit: u64, threshold_percent: f64, }, DandelionStemStarted { tx_hash: [u8; 32], current_peer: String, next_peer: String, }, DandelionStemAdvanced { tx_hash: [u8; 32], hop_count: u8, next_peer: String, }, DandelionFluffed { tx_hash: [u8; 32], stem_hops: u8, }, DandelionStemPathExpired { peer_addr: String, }, CompactBlockReceived { block_hash: [u8; 32], height: u64, short_ids_count: usize, }, BlockReconstructionStarted { block_hash: [u8; 32], height: u64, }, BlockReconstructionCompleted { block_hash: [u8; 32], height: u64, success: bool, missing_txs: usize, }, FibreBlockEncoded { block_hash: [u8; 32], height: u64, chunks: usize, encoding_time_ms: u64, }, FibreBlockSent { block_hash: [u8; 32], height: u64, peer_addr: String, }, CompanionUdpPeerRegistered { p2p_peer_addr: String, udp_addr: String, }, CompanionUdpPeerUnregistered { p2p_peer_addr: String, }, PackageReceived { package_id: Vec<u8>, transaction_count: usize, peer_addr: String, }, PackageRejected { package_id: Vec<u8>, reason: String, peer_addr: String, }, UtxoCommitmentReceived { block_hash: [u8; 32], height: u64, commitment_hash: [u8; 32], peer_addr: String, }, UtxoCommitmentVerified { block_hash: [u8; 32], height: u64, commitment_hash: [u8; 32], valid: bool, }, BanListShared { peer_addr: String, ban_count: usize, }, BanListReceived { peer_addr: String, ban_count: usize, }, SelectiveSyncPolicyApplied { policy_source: String, registry_count: usize, }, ActionExecuted { action_id: String, action_type: String, target: String, success: bool, }, ModulePurchaseCompleted { module_id: String, payment_id: String, amount_sats: u64, }, StratumClientConnected { endpoint: String, protocol_version: u32, }, StratumClientDisconnected { endpoint: String, reason: String, }, IBDBlockFiltered { block_hash: [u8; 32], height: u64, reason: String, }, ModuleDiscovered { module_name: String, version: String, source: String, }, ModuleInstalled { module_name: String, version: String, }, ModuleUpdated { module_name: String, old_version: String, new_version: String, }, ModuleRemoved { module_name: String, version: String, },
}
Expand description

Event payload types

Variants§

§

NewBlock

Fields

§block_hash: [u8; 32]
§height: u64
§

NewTransaction

Fields

§tx_hash: [u8; 32]
§

BlockDisconnected

Fields

§hash: [u8; 32]
§height: u64
§

ChainReorg

Fields

§old_tip: [u8; 32]
§new_tip: [u8; 32]
§

PaymentRequestCreated

Fields

§payment_id: String
§amount_sats: u64
§invoice: Option<String>
§

PaymentSettled

Fields

§payment_id: String
§tx_hash: [u8; 32]
§confirmations: u32
§

PaymentFailed

Fields

§payment_id: String
§reason: String
§

PaymentVerified

Fields

§payment_id: String
§amount_msats: u64
§invoice: String
§

PaymentRouteFound

Fields

§payment_id: String
§route_hops: usize
§route_cost_msats: u64
§

PaymentRouteFailed

Fields

§payment_id: String
§reason: String
§

ChannelOpened

Fields

§channel_id: String
§peer_pubkey: Vec<u8>
§capacity_sats: u64
§

ChannelClosed

Fields

§channel_id: String
§reason: String
§

BlockMined

Fields

§block_hash: [u8; 32]
§height: u64
§miner_id: Option<String>
§

BlockTemplateUpdated

Fields

§prev_hash: [u8; 32]
§height: u64
§tx_count: usize
§

MiningDifficultyChanged

Fields

§old_difficulty: u32
§new_difficulty: u32
§height: u64
§

MiningJobCreated

Fields

§job_id: String
§prev_hash: [u8; 32]
§height: u64
§

ShareSubmitted

Fields

§job_id: String
§share_hash: [u8; 32]
§miner_id: Option<String>
§

MergeMiningReward

Fields

§secondary_chain: String
§reward_amount: u64
§block_hash: [u8; 32]
§

MiningPoolConnected

Fields

§pool_url: String
§pool_id: Option<String>
§

MiningPoolDisconnected

Fields

§pool_url: String
§reason: String
§

GovernanceProposalCreated

Fields

§proposal_id: String
§repository: String
§pr_number: u64
§tier: String
§

GovernanceProposalVoted

Fields

§proposal_id: String
§voter: String
§vote: String
§

GovernanceProposalMerged

Fields

§proposal_id: String
§repository: String
§pr_number: u64
§

WebhookSent

Fields

§webhook_url: String
§event_type: String
§success: bool
§

WebhookFailed

Fields

§webhook_url: String
§event_type: String
§error: String
§

GovernanceForkDetected

Fields

§fork_id: String
§ruleset_version: String
§adoption_count: usize
§

PeerConnected

Fields

§peer_addr: String
§transport_type: String
§services: u64
§version: u32
§

PeerDisconnected

Fields

§peer_addr: String
§reason: String
§

PeerBanned

Fields

§peer_addr: String
§reason: String
§ban_duration_seconds: u64
§

PeerUnbanned

Fields

§peer_addr: String
§

MessageReceived

Fields

§peer_addr: String
§message_type: String
§message_size: usize
§protocol_version: u32
§

MessageSent

Fields

§peer_addr: String
§message_type: String
§message_size: usize
§

BroadcastStarted

Fields

§message_type: String
§target_peers: usize
§

BroadcastCompleted

Fields

§message_type: String
§successful: usize
§failed: usize
§

RouteDiscovered

Fields

§destination: Vec<u8>
§route_path: Vec<String>
§route_cost: u64
§

RouteFailed

Fields

§destination: Vec<u8>
§reason: String
§

ConnectionAttempt

Fields

§peer_addr: String
§success: bool
§

AddressDiscovered

Fields

§peer_addr: String
§source: String
§

AddressExpired

Fields

§peer_addr: String
§

NetworkPartition

Fields

§partition_id: Vec<u8>
§disconnected_peers: Vec<String>
§partition_size: usize
§

NetworkReconnected

Fields

§partition_id: Vec<u8>
§reconnected_peers: Vec<String>
§

DoSAttackDetected

Fields

§peer_addr: String
§attack_type: String
§severity: String
§

RateLimitExceeded

Fields

§peer_addr: String
§limit_type: String
§current_rate: f64
§limit: f64
§

BlockValidationStarted

Fields

§block_hash: [u8; 32]
§height: u64
§

BlockValidationCompleted

Fields

§block_hash: [u8; 32]
§height: u64
§success: bool
§validation_time_ms: u64
§

ScriptVerificationStarted

Fields

§tx_hash: [u8; 32]
§input_index: usize
§

ScriptVerificationCompleted

Fields

§tx_hash: [u8; 32]
§input_index: usize
§success: bool
§verification_time_ms: u64
§

UTXOValidationStarted

Fields

§block_hash: [u8; 32]
§height: u64
§

UTXOValidationCompleted

Fields

§block_hash: [u8; 32]
§height: u64
§success: bool
§

DifficultyAdjusted

Fields

§old_difficulty: u32
§new_difficulty: u32
§height: u64
§

SoftForkActivated

Fields

§fork_name: String
§height: u64
§

SoftForkLockedIn

Fields

§fork_name: String
§height: u64
§

ConsensusRuleViolation

Fields

§rule_name: String
§block_hash: Option<[u8; 32]>
§tx_hash: Option<[u8; 32]>
§error: String
§

HeadersSyncStarted

Fields

§start_height: u64
§

HeadersSyncProgress

Fields

§current_height: u64
§target_height: u64
§progress_percent: f64
§

HeadersSyncCompleted

Fields

§final_height: u64
§duration_seconds: u64
§

BlockSyncStarted

Fields

§start_height: u64
§target_height: u64
§

BlockSyncProgress

Fields

§current_height: u64
§target_height: u64
§progress_percent: f64
§blocks_per_second: f64
§

BlockSyncCompleted

Fields

§final_height: u64
§duration_seconds: u64
§

SyncStateChanged

Fields

§old_state: String
§new_state: String
§

MempoolTransactionAdded

Fields

§tx_hash: [u8; 32]
§fee_rate: f64
§mempool_size: usize
§

MempoolTransactionRemoved

Fields

§tx_hash: [u8; 32]
§reason: String
§mempool_size: usize
§

MempoolThresholdExceeded

Fields

§current_size: usize
§threshold: usize
§

FeeRateChanged

Fields

§old_fee_rate: f64
§new_fee_rate: f64
§mempool_size: usize
§

MempoolCleared

Fields

§cleared_count: usize
§

StorageRead

Fields

§operation: String
§duration_ms: u64
§

StorageWrite

Fields

§operation: String
§duration_ms: u64
§bytes_written: usize
§

StorageQuery

Fields

§query_type: String
§duration_ms: u64
§

DatabaseBackupStarted

Fields

§backup_path: String
§

DatabaseBackupCompleted

Fields

§backup_path: String
§success: bool
§size_bytes: u64
§duration_seconds: u64
§

ModuleLoaded

Fields

§module_name: String
§version: String
§

ModuleUnloaded

Fields

§module_name: String
§version: String
§

ModuleReloaded

Fields

§module_name: String
§old_version: String
§new_version: String
§

ModuleStarted

Fields

§module_name: String
§

ModuleStopped

Fields

§module_name: String
§

MeshPacketReceived

Fields

§packet_data: Vec<u8>
§peer_addr: String
§

StratumV2MessageReceived

Fields

§message_data: Vec<u8>
§peer_addr: String
§

ModuleCrashed

Fields

§module_name: String
§error: String
§

ModuleHealthChanged

Fields

§module_name: String
§old_health: String
§new_health: String
§

ModuleStateChanged

Fields

§module_name: String
§old_state: String
§new_state: String
§

ConfigLoaded

Fields

§changed_sections: Vec<String>

Configuration sections that changed (e.g., [“network”, “governance”])

§config_json: Option<String>

Full config as JSON string (for modules that need full config)

§

NodeShutdown

Fields

§reason: String

Shutdown reason (e.g., “signal”, “rpc”, “error”)

§timeout_seconds: u64

Graceful shutdown timeout in seconds

§

NodeShutdownCompleted

Fields

§duration_ms: u64

Shutdown duration in milliseconds

§

NodeStartupCompleted

Fields

§duration_ms: u64

Startup duration in milliseconds

§components: Vec<String>

Components initialized

§

MaintenanceStarted

Fields

§maintenance_type: String

Maintenance type (e.g., “backup”, “cleanup”, “prune”)

§estimated_duration_seconds: Option<u64>

Estimated duration in seconds (if known)

§

MaintenanceCompleted

Fields

§maintenance_type: String

Maintenance type

§success: bool

Success status

§duration_ms: u64

Duration in milliseconds

§results: Option<String>

Results/statistics (optional JSON string)

§

DataMaintenance

Fields

§operation: String

Maintenance operation type: “cleanup” (delete old data), “flush” (write pending data), or “both”

§urgency: String

Urgency level: “low” (periodic), “medium” (scheduled), “high” (shutdown/low-disk)

§reason: String

Reason for maintenance (e.g., “periodic”, “shutdown”, “low_disk”, “manual”)

§target_age_days: Option<u64>

Target age for cleanup in days (if operation includes cleanup)

§timeout_seconds: Option<u64>

Timeout in seconds (for high urgency operations)

§

HealthCheck

Fields

§check_type: String

Health check type (e.g., “periodic”, “manual”, “startup”)

§node_healthy: bool

Node health status

§health_report: Option<String>

Health report (optional JSON string)

§

DiskSpaceLow

Fields

§available_bytes: u64

Available space in bytes

§total_bytes: u64

Total space in bytes

§percent_free: f64

Percentage free

§disk_path: String

Disk path

§

ResourceLimitWarning

Fields

§resource_type: String

Resource type (e.g., “memory”, “cpu”, “disk”, “network”)

§usage_percent: f64

Current usage percentage

§current_usage: u64

Current usage value

§limit: u64

Limit value

§threshold_percent: f64

Warning threshold percentage

§

DandelionStemStarted

Fields

§tx_hash: [u8; 32]
§current_peer: String
§next_peer: String
§

DandelionStemAdvanced

Fields

§tx_hash: [u8; 32]
§hop_count: u8
§next_peer: String
§

DandelionFluffed

Fields

§tx_hash: [u8; 32]
§stem_hops: u8
§

DandelionStemPathExpired

Fields

§peer_addr: String
§

CompactBlockReceived

Fields

§block_hash: [u8; 32]
§height: u64
§short_ids_count: usize
§

BlockReconstructionStarted

Fields

§block_hash: [u8; 32]
§height: u64
§

BlockReconstructionCompleted

Fields

§block_hash: [u8; 32]
§height: u64
§success: bool
§missing_txs: usize
§

FibreBlockEncoded

Fields

§block_hash: [u8; 32]
§height: u64
§chunks: usize
§encoding_time_ms: u64
§

FibreBlockSent

Fields

§block_hash: [u8; 32]
§height: u64
§peer_addr: String
§

CompanionUdpPeerRegistered

Fields

§p2p_peer_addr: String

P2P peer key (SocketAddr display for TCP/QUIC).

§udp_addr: String

Companion UDP endpoint (same IP as P2P, port = P2P port + 1).

§

CompanionUdpPeerUnregistered

Fields

§p2p_peer_addr: String
§

PackageReceived

Fields

§package_id: Vec<u8>
§transaction_count: usize
§peer_addr: String
§

PackageRejected

Fields

§package_id: Vec<u8>
§reason: String
§peer_addr: String
§

UtxoCommitmentReceived

Fields

§block_hash: [u8; 32]
§height: u64
§commitment_hash: [u8; 32]
§peer_addr: String
§

UtxoCommitmentVerified

Fields

§block_hash: [u8; 32]
§height: u64
§commitment_hash: [u8; 32]
§valid: bool
§

BanListShared

Fields

§peer_addr: String
§ban_count: usize
§

BanListReceived

Fields

§peer_addr: String
§ban_count: usize
§

SelectiveSyncPolicyApplied

Fields

§policy_source: String
§registry_count: usize
§

ActionExecuted

Fields

§action_id: String
§action_type: String
§target: String
§success: bool
§

ModulePurchaseCompleted

Fields

§module_id: String
§payment_id: String
§amount_sats: u64
§

StratumClientConnected

Fields

§endpoint: String
§protocol_version: u32
§

StratumClientDisconnected

Fields

§endpoint: String
§reason: String
§

IBDBlockFiltered

Fields

§block_hash: [u8; 32]
§height: u64
§reason: String
§

ModuleDiscovered

Fields

§module_name: String
§version: String
§source: String
§

ModuleInstalled

Fields

§module_name: String
§version: String
§

ModuleUpdated

Fields

§module_name: String
§old_version: String
§new_version: String
§

ModuleRemoved

Fields

§module_name: String
§version: String

Implementations§

Source§

impl EventPayload

Typed payload extraction for event handlers.

Use these helpers in #[on_event] handlers to get event-specific data without manual matching. Example: if let Some((hash, height)) = event.payload.as_new_block() { ... }

Source

pub fn as_new_block(&self) -> Option<(&[u8; 32], u64)>

Source

pub fn as_new_transaction(&self) -> Option<&[u8; 32]>

Source

pub fn as_module_loaded(&self) -> Option<(&str, &str)>

Source

pub fn as_block_disconnected(&self) -> Option<(&[u8; 32], u64)>

Source

pub fn as_chain_reorg(&self) -> Option<(&[u8; 32], &[u8; 32])>

Trait Implementations§

Source§

impl Clone for EventPayload

Source§

fn clone(&self) -> EventPayload

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for EventPayload

Source§

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

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for EventPayload

Source§

fn deserialize<__D>( __deserializer: __D, ) -> Result<EventPayload, <__D as Deserializer<'de>>::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl Serialize for EventPayload

Source§

fn serialize<__S>( &self, __serializer: __S, ) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations§

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> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
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> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts 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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts 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
Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

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

Initializes a with the given initializer. Read more
Source§

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

Dereferences the given pointer. Read more
Source§

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

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

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

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

Source§

fn and<P, B, E>(self, other: P) -> And<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow only if self and other return Action::Follow. Read more
Source§

fn or<P, B, E>(self, other: P) -> Or<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow if either self or other returns Action::Follow. Read more
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

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

Source§

type Error = Infallible

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

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

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.
Source§

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

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,