pub trait TypesLoader {
// Required method
async fn fetch_types(&self, uri: &Uri) -> Result<Types, TypesFetchError>;
}Expand description
Type providing remote EIP712 type definitions from an URI.
A default implementation is provided for the () type that always return
TypesFetchError::Unsupported.
Required Methods§
Sourceasync fn fetch_types(&self, uri: &Uri) -> Result<Types, TypesFetchError>
async fn fetch_types(&self, uri: &Uri) -> Result<Types, TypesFetchError>
Fetches the type definitions located behind the given uri.
This is an asynchronous function returning a Self::Fetch future that
resolves into ether the EIP712 Types or an error
of type TypesFetchError.
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.
Implementations on Foreign Types§
Source§impl TypesLoader for ()
Simple EIP712 loader implementation that always return
TypesFetchError::Unsupported.
impl TypesLoader for ()
Simple EIP712 loader implementation that always return
TypesFetchError::Unsupported.