pub struct ExecutionClientFactoryRegistry { /* private fields */ }Expand description
Registry for managing execution client factories.
Allows dynamic registration and lookup of factories by name, enabling a plugin-like architecture for different execution providers.
Implementations§
Source§impl ExecutionClientFactoryRegistry
impl ExecutionClientFactoryRegistry
Sourcepub fn register(
&mut self,
name: String,
factory: Box<dyn ExecutionClientFactory>,
) -> Result<()>
pub fn register( &mut self, name: String, factory: Box<dyn ExecutionClientFactory>, ) -> Result<()>
Registers an execution client factory.
§Errors
Returns an error if a factory with the same name is already registered.
Sourcepub fn get(&self, name: &str) -> Option<&dyn ExecutionClientFactory>
pub fn get(&self, name: &str) -> Option<&dyn ExecutionClientFactory>
Gets a registered factory by name (if found).
Trait Implementations§
Source§impl Default for ExecutionClientFactoryRegistry
impl Default for ExecutionClientFactoryRegistry
Source§fn default() -> ExecutionClientFactoryRegistry
fn default() -> ExecutionClientFactoryRegistry
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for ExecutionClientFactoryRegistry
impl !RefUnwindSafe for ExecutionClientFactoryRegistry
impl Send for ExecutionClientFactoryRegistry
impl Sync for ExecutionClientFactoryRegistry
impl Unpin for ExecutionClientFactoryRegistry
impl !UnwindSafe for ExecutionClientFactoryRegistry
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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