pub trait IntoRootProvider<N: Network = Ethereum> {
// Required method
fn into_root_provider(
self,
) -> impl Future<Output = Result<RootProvider<N>, Error>> + Send;
}Expand description
Conversion trait for types that can be turned into an Alloy RootProvider.
This is primarily used by RobustProviderBuilder to accept different provider types and
connection strings.
Required Methods§
Sourcefn into_root_provider(
self,
) -> impl Future<Output = Result<RootProvider<N>, Error>> + Send
fn into_root_provider( self, ) -> impl Future<Output = Result<RootProvider<N>, Error>> + Send
Convert self into a RootProvider.
§Errors
Returns an error if the underlying provider cannot be constructed or connected.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.