Struct akd::storage::types::ValueState
source · pub struct ValueState {
pub plaintext_val: AkdValue,
pub version: u64,
pub label: NodeLabel,
pub epoch: u64,
pub username: AkdLabel,
}
Expand description
The state of the value for a given key, starting at a particular epoch.
Fields
plaintext_val: AkdValue
The plaintext value of the user information in the directory
version: u64
The version of the user’s value-state
label: NodeLabel
The Node Label
epoch: u64
The epoch this value state was published in
username: AkdLabel
The username associated to this value state (username + epoch is the record key)
Trait Implementations
sourceimpl Clone for ValueState
impl Clone for ValueState
sourcefn clone(&self) -> ValueState
fn clone(&self) -> ValueState
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresourceimpl Debug for ValueState
impl Debug for ValueState
sourceimpl Hash for ValueState
impl Hash for ValueState
sourceimpl PartialEq<ValueState> for ValueState
impl PartialEq<ValueState> for ValueState
sourcefn eq(&self, other: &ValueState) -> bool
fn eq(&self, other: &ValueState) -> bool
sourceimpl Storable for ValueState
impl Storable for ValueState
type StorageKey = ValueStateKey
type StorageKey = ValueStateKey
This particular storage will have a key type
sourcefn data_type() -> StorageType
fn data_type() -> StorageType
Must return a valid storage type
sourcefn get_id(&self) -> ValueStateKey
fn get_id(&self) -> ValueStateKey
Retrieve an instance of the id of this storable. The combination of the
storable’s StorageType and this id are globally unique Read more
sourcefn get_full_binary_key_id(key: &ValueStateKey) -> Vec<u8>
fn get_full_binary_key_id(key: &ValueStateKey) -> Vec<u8>
Retrieve the full binary version of a key (for comparisons)
sourcefn key_from_full_binary(bin: &[u8]) -> Result<ValueStateKey, String>
fn key_from_full_binary(bin: &[u8]) -> Result<ValueStateKey, String>
Reformat a key from the full-binary specification
sourcefn get_full_binary_id(&self) -> Vec<u8>
fn get_full_binary_id(&self) -> Vec<u8>
Retrieve the full binary version of a key (for comparisons)
impl Eq for ValueState
impl StructuralEq for ValueState
impl StructuralPartialEq for ValueState
Auto Trait Implementations
impl RefUnwindSafe for ValueState
impl Send for ValueState
impl Sync for ValueState
impl Unpin for ValueState
impl UnwindSafe for ValueState
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
sourceimpl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
sourcefn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.