pub struct EvmDecoder;Expand description
The EVM chain decoder. Thread-safe, cheap to clone (no heap state).
Implementations§
Source§impl EvmDecoder
impl EvmDecoder
Trait Implementations§
Source§impl ChainDecoder for EvmDecoder
impl ChainDecoder for EvmDecoder
Source§fn decode_batch(
&self,
logs: &[RawEvent],
registry: &dyn SchemaRegistry,
mode: ErrorMode,
progress: Option<&dyn ProgressCallback>,
) -> Result<BatchDecodeResult, BatchDecodeError>
fn decode_batch( &self, logs: &[RawEvent], registry: &dyn SchemaRegistry, mode: ErrorMode, progress: Option<&dyn ProgressCallback>, ) -> Result<BatchDecodeResult, BatchDecodeError>
Override default batch with Rayon parallel decode.
Source§fn chain_family(&self) -> ChainFamily
fn chain_family(&self) -> ChainFamily
Returns the chain family this decoder handles.
Source§fn fingerprint(&self, raw: &RawEvent) -> EventFingerprint
fn fingerprint(&self, raw: &RawEvent) -> EventFingerprint
Compute the event fingerprint from a raw event.
For EVM this is
topics[0]; for Solana it’s a discriminator hash, etc.Source§fn decode_event(
&self,
raw: &RawEvent,
schema: &Schema,
) -> Result<DecodedEvent, DecodeError>
fn decode_event( &self, raw: &RawEvent, schema: &Schema, ) -> Result<DecodedEvent, DecodeError>
Decode a single raw event using the provided schema.
Source§fn supports_abi_guess(&self) -> bool
fn supports_abi_guess(&self) -> bool
Whether this decoder can attempt to guess/auto-detect a schema
from raw bytes when no schema is found in the registry.
Source§impl Clone for EvmDecoder
impl Clone for EvmDecoder
Source§fn clone(&self) -> EvmDecoder
fn clone(&self) -> EvmDecoder
Returns a duplicate 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 Debug for EvmDecoder
impl Debug for EvmDecoder
Source§impl Default for EvmDecoder
impl Default for EvmDecoder
Source§fn default() -> EvmDecoder
fn default() -> EvmDecoder
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for EvmDecoder
impl RefUnwindSafe for EvmDecoder
impl Send for EvmDecoder
impl Sync for EvmDecoder
impl Unpin for EvmDecoder
impl UnsafeUnpin for EvmDecoder
impl UnwindSafe for EvmDecoder
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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>
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 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>
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