pub struct BatchEngine { /* private fields */ }Expand description
Batch decode engine.
Implementations§
Source§impl BatchEngine
impl BatchEngine
pub fn new(registry: Arc<dyn SchemaRegistry>) -> Self
Sourcepub fn add_decoder(
&mut self,
chain_slug: impl Into<String>,
decoder: Arc<dyn ChainDecoder>,
)
pub fn add_decoder( &mut self, chain_slug: impl Into<String>, decoder: Arc<dyn ChainDecoder>, )
Register a decoder for a given chain slug.
Sourcepub fn decode(&self, req: BatchRequest) -> Result<BatchResult, BatchDecodeError>
pub fn decode(&self, req: BatchRequest) -> Result<BatchResult, BatchDecodeError>
Execute a batch decode request.
Auto Trait Implementations§
impl Freeze for BatchEngine
impl !RefUnwindSafe for BatchEngine
impl Send for BatchEngine
impl Sync for BatchEngine
impl Unpin for BatchEngine
impl UnsafeUnpin for BatchEngine
impl !UnwindSafe for BatchEngine
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