Struct fog_pack::entry::Entry[][src]

pub struct Entry { /* fields omitted */ }

Holds serialized data associated with a parent document and a key string.

An Entry holds a piece of serialized data, which may be deserialized by calling deserialize.

Implementations

impl Entry[src]

pub fn parent(&self) -> &Hash[src]

Get the hash of the Entry’s parent Document.

pub fn key(&self) -> &str[src]

Get the Entry’s string key.

pub fn signer(&self) -> Option<&Identity>[src]

Get the Identity of the signer of this document, if the document is signed.

pub fn hash(&self) -> Hash[src]

Get the hash of the complete entry. This can change if the entry is signed again with the sign function.

pub fn deserialize<'de, D: Deserialize<'de>>(&'de self) -> Result<D>[src]

Deserialize the entry’s contained data into a value.

pub fn compression(self, setting: Option<u8>) -> Self[src]

Override the default compression settings. None will disable compression. Some(level) will compress with the provided level as the setting for the algorithm.

pub fn sign(self, key: &IdentityKey) -> Result<Self>[src]

Sign the entry, or or replace the existing signature if one exists already. Fails if the signature would grow the entry size beyond the maximum allowed. In the event of a failure. the entry is unmodified.

Auto Trait Implementations

impl RefUnwindSafe for Entry

impl Send for Entry

impl Sync for Entry

impl Unpin for Entry

impl UnwindSafe for Entry

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,