Type Definition holo_hash::AnyDhtHash
source · [−]Expand description
The hash of anything referrable in the DHT. This is a composite of either an EntryHash or a HeaderHash
Implementations
sourceimpl AnyDhtHash
impl AnyDhtHash
sourcepub fn into_primitive(self) -> AnyDhtHashPrimitive
pub fn into_primitive(self) -> AnyDhtHashPrimitive
Match on the primitive hash type represented by this composite hash type
sourcepub fn into_entry_hash(self) -> Option<EntryHash>
pub fn into_entry_hash(self) -> Option<EntryHash>
If this hash represents an EntryHash, return it, else None
sourcepub fn into_header_hash(self) -> Option<HeaderHash>
pub fn into_header_hash(self) -> Option<HeaderHash>
If this hash represents a HeaderHash, return it, else None
Trait Implementations
sourceimpl From<HoloHash<Agent>> for AnyDhtHash
impl From<HoloHash<Agent>> for AnyDhtHash
sourcefn from(hash: AgentPubKey) -> Self
fn from(hash: AgentPubKey) -> Self
Converts to this type from the input type.
sourceimpl From<HoloHash<AnyLinkable>> for AnyDhtHash
impl From<HoloHash<AnyLinkable>> for AnyDhtHash
sourcefn from(hash: AnyLinkableHash) -> Self
fn from(hash: AnyLinkableHash) -> Self
Converts to this type from the input type.
sourceimpl From<HoloHash<Entry>> for AnyDhtHash
impl From<HoloHash<Entry>> for AnyDhtHash
sourceimpl From<HoloHash<Header>> for AnyDhtHash
impl From<HoloHash<Header>> for AnyDhtHash
sourcefn from(hash: HeaderHash) -> Self
fn from(hash: HeaderHash) -> Self
Converts to this type from the input type.