pub struct CacheNamespace {
pub name: &'static str,
pub schema: u32,
}Expand description
A kind of cache entry: a name and the schema of its payload.
The namespace is a parameter of every store call, so a host can lay entries out and report them per namespace. The schema is part of every key and envelope: raising it makes every entry written under the old one a miss.
Fields§
§name: &'static strA short, stable name such as modules: lower-case ASCII letters, digits, . and -, at most 64 bytes.
schema: u32The version of the payload’s layout.
Implementations§
Trait Implementations§
Source§impl Clone for CacheNamespace
impl Clone for CacheNamespace
impl Copy for CacheNamespace
Source§impl Debug for CacheNamespace
impl Debug for CacheNamespace
impl Eq for CacheNamespace
Source§impl Hash for CacheNamespace
impl Hash for CacheNamespace
Source§impl Ord for CacheNamespace
impl Ord for CacheNamespace
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
Source§impl PartialEq for CacheNamespace
impl PartialEq for CacheNamespace
Source§impl PartialOrd for CacheNamespace
impl PartialOrd for CacheNamespace
impl StructuralPartialEq for CacheNamespace
Auto Trait Implementations§
impl Forget for CacheNamespace
impl Freeze for CacheNamespace
impl Move for CacheNamespace
impl RefUnwindSafe for CacheNamespace
impl Send for CacheNamespace
impl Sync for CacheNamespace
impl Unpin for CacheNamespace
impl UnsafeUnpin for CacheNamespace
impl UnwindSafe for CacheNamespace
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<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.