pub struct NullCache {}Expand description
A cache that will always return NoCache in lookups, and does no actual work.
Trait Implementations§
Source§impl<K: Key, V: Value> ObjectCache<K, V> for NullCache
impl<K: Key, V: Value> ObjectCache<K, V> for NullCache
Source§fn lookup_or_reserve(&self, _key: &K) -> ObjectCacheResult<'_, V>
fn lookup_or_reserve(&self, _key: &K) -> ObjectCacheResult<'_, V>
Looks up a key in the cache and may return a cached value for it. See
ObjectCacheResult.Source§fn invalidate(&self, _key: K, _value: Option<V>)
fn invalidate(&self, _key: K, _value: Option<V>)
Removes key from cache if
value is None, invalidates the results of placeholders that have
not been resolved. When value is provided then the value may be inserted, and may replace
an existing value.Auto Trait Implementations§
impl Freeze for NullCache
impl RefUnwindSafe for NullCache
impl Send for NullCache
impl Sync for NullCache
impl Unpin for NullCache
impl UnwindSafe for NullCache
Blanket Implementations§
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, D> Encode<Ambiguous1, D> for Twhere
D: ResourceDialect,
impl<T, D> Encode<Ambiguous1, D> for Twhere
D: ResourceDialect,
§impl<T, D> Encode<Ambiguous2, D> for Twhere
D: ResourceDialect,
impl<T, D> Encode<Ambiguous2, D> for Twhere
D: ResourceDialect,
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