pub trait ByUuid: BaseModel {
// Required method
fn by_uuid<'life0, 'async_trait>(
database: &'life0 Database,
uuid: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Self, DatabaseError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
// Provided methods
fn by_uuid_cached<'life0, 'async_trait>(
database: &'life0 Database,
uuid: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Self, Error>> + Send + 'async_trait>>
where Self: Send + 'async_trait,
'life0: 'async_trait { ... }
fn by_uuid_optional<'life0, 'async_trait>(
database: &'life0 Database,
uuid: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Option<Self>, DatabaseError>> + Send + 'async_trait>>
where Self: Send + 'async_trait,
'life0: 'async_trait { ... }
fn by_uuid_optional_cached<'life0, 'async_trait>(
database: &'life0 Database,
uuid: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Option<Self>, Error>> + Send + 'async_trait>>
where Self: Send + 'async_trait,
'life0: 'async_trait { ... }
fn get_fetchable(uuid: Uuid) -> Fetchable<Self> { ... }
fn get_fetchable_from_row(
row: &PgRow,
column: impl AsRef<str>,
) -> Option<Fetchable<Self>> { ... }
}Required Methods§
fn by_uuid<'life0, 'async_trait>(
database: &'life0 Database,
uuid: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Self, DatabaseError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Provided Methods§
fn by_uuid_cached<'life0, 'async_trait>(
database: &'life0 Database,
uuid: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Self, Error>> + Send + 'async_trait>>where
Self: Send + 'async_trait,
'life0: 'async_trait,
fn by_uuid_optional<'life0, 'async_trait>(
database: &'life0 Database,
uuid: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Option<Self>, DatabaseError>> + Send + 'async_trait>>where
Self: Send + 'async_trait,
'life0: 'async_trait,
fn by_uuid_optional_cached<'life0, 'async_trait>(
database: &'life0 Database,
uuid: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Option<Self>, Error>> + Send + 'async_trait>>where
Self: Send + 'async_trait,
'life0: 'async_trait,
fn get_fetchable(uuid: Uuid) -> Fetchable<Self>
fn get_fetchable_from_row( row: &PgRow, column: impl AsRef<str>, ) -> Option<Fetchable<Self>>
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.