pub struct External;
Expand description
The $name PrimitiveHashType
Trait Implementations§
source§impl<'de> Deserialize<'de> for External
impl<'de> Deserialize<'de> for External
source§fn deserialize<D>(deserializer: D) -> Result<External, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<External, D::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Ord for External
impl Ord for External
source§impl PartialEq for External
impl PartialEq for External
source§impl PartialOrd for External
impl PartialOrd for External
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl PrimitiveHashType for External
impl PrimitiveHashType for External
impl Copy for External
impl Eq for External
impl HashTypeAsync for External
External hashes have a DHT location and hash prefix like all other native holochain hashes but are NOT found/fetchable on the DHT. External hashing makes no assumptions about the data that was digested to create the hash so arbitrary bytes can be passed in. It is valid to EITHER use an existing 32 byte hash/data as literal bytes for an external hash (literal+prefix, no data loss) OR digest arbitrary data into an external hash (support all data, opaque result).
impl StructuralPartialEq for External
Auto Trait Implementations§
impl RefUnwindSafe for External
impl Send for External
impl Sync for External
impl Unpin for External
impl UnwindSafe for External
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<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.source§impl<P> HashType for Pwhere
P: PrimitiveHashType,
impl<P> HashType for Pwhere
P: PrimitiveHashType,
source§fn get_prefix(self) -> &'static [u8] ⓘ
fn get_prefix(self) -> &'static [u8] ⓘ
Get the 3-byte prefix for the underlying primitive hash type
source§fn try_from_prefix(prefix: &[u8]) -> Result<P, HoloHashError>
fn try_from_prefix(prefix: &[u8]) -> Result<P, HoloHashError>
Given a 3-byte prefix, return the corresponding HashType, or error if mismatched.
Trivial for PrimitiveHashType, but useful for composite types