pub struct Fetchable<M: ByUuid> {
pub uuid: Uuid,
/* private fields */
}Fields§
§uuid: UuidImplementations§
Source§impl<M: ByUuid + Send> Fetchable<M>
impl<M: ByUuid + Send> Fetchable<M>
pub async fn fetch(&self, database: &Database) -> Result<M, DatabaseError>
pub async fn fetch_cached(&self, database: &Database) -> Result<M, Error>
pub async fn fetch_optional( &self, database: &Database, ) -> Result<Option<M>, DatabaseError>
pub async fn fetch_optional_cached( &self, database: &Database, ) -> Result<Option<M>, Error>
Trait Implementations§
Source§impl<'de, M: ByUuid> Deserialize<'de> for Fetchable<M>
impl<'de, M: ByUuid> Deserialize<'de> for Fetchable<M>
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl<M: Copy + ByUuid> Copy for Fetchable<M>
Auto Trait Implementations§
impl<M> Freeze for Fetchable<M>
impl<M> RefUnwindSafe for Fetchable<M>where
M: RefUnwindSafe,
impl<M> Send for Fetchable<M>where
M: Send,
impl<M> Sync for Fetchable<M>where
M: Sync,
impl<M> Unpin for Fetchable<M>where
M: Unpin,
impl<M> UnwindSafe for Fetchable<M>where
M: UnwindSafe,
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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> Chain<T> for T
impl<T> Chain<T> for T
§impl<T> Classify for T
impl<T> Classify for T
type Classified = T
fn classify(self) -> T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Declassify for T
impl<T> Declassify for T
type Declassified = T
fn declassify(self) -> T
§impl<T> FromBase64 for Twhere
T: for<'de> Deserialize<'de>,
impl<T> FromBase64 for Twhere
T: for<'de> Deserialize<'de>,
§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