pub trait Manager {
type Connection;
type Error: for<'a> From<&'a str>;
// Required methods
async fn connect(&self) -> Result<Self::Connection, Self::Error>;
async fn check(
&self,
conn: &mut Self::Connection
) -> Result<(), Self::Error>;
}
Expand description
Manager create Connection and check Connection
Required Associated Types§
Required Methods§
sourceasync fn connect(&self) -> Result<Self::Connection, Self::Error>
async fn connect(&self) -> Result<Self::Connection, Self::Error>
create Connection and check Connection
Object Safety§
This trait is not object safe.