pub enum Lifetime {
Volatile,
Persistent,
Custom(u32),
}
Expand description
The lifetime of a key indicates where it is stored and which application and system actions will create and destroy it.
Variants
Volatile
A volatile key only exists as long as the identifier to it is not destroyed.
Persistent
A persistent key remains in storage until it is explicitly destroyed or until the corresponding storage area is wiped.
Custom(u32)
Implementations can offer other storage areas designated by other lifetime values as implementation-specific extensions.
Trait Implementations
sourceimpl<'de> Deserialize<'de> for Lifetime
impl<'de> Deserialize<'de> for Lifetime
sourcefn deserialize<__D>(
__deserializer: __D
) -> Result<Lifetime, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D
) -> Result<Lifetime, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
sourceimpl PartialEq<Lifetime> for Lifetime
impl PartialEq<Lifetime> for Lifetime
sourceimpl Serialize for Lifetime
impl Serialize for Lifetime
sourcefn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl Copy for Lifetime
impl Eq for Lifetime
impl StructuralEq for Lifetime
impl StructuralPartialEq for Lifetime
Auto Trait Implementations
impl RefUnwindSafe for Lifetime
impl Send for Lifetime
impl Sync for Lifetime
impl Unpin for Lifetime
impl UnwindSafe for Lifetime
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more