#[repr(transparent)]pub struct Hmac<T>(_)
where
T: Hash;Expand description
A hash computed from a RFC 2104 HMAC. Parameterized by the underlying hash function.
Trait Implementations§
§impl<'de, T> Deserialize<'de> for Hmac<T>where
T: Hash + Deserialize<'de>,
impl<'de, T> Deserialize<'de> for Hmac<T>where T: Hash + Deserialize<'de>,
§fn deserialize<D>(d: D) -> Result<Hmac<T>, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
fn deserialize<D>(d: D) -> Result<Hmac<T>, <D as Deserializer<'de>>::Error>where D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
§impl<T> Hash for Hmac<T>where
T: Hash,
impl<T> Hash for Hmac<T>where T: Hash,
§type Engine = HmacEngine<T>
type Engine = HmacEngine<T>
A hashing engine which bytes can be serialized into. It is expected
to implement the
io::Write trait, and to never return errors under
any conditions.§fn from_engine(e: HmacEngine<T>) -> Hmac<T>
fn from_engine(e: HmacEngine<T>) -> Hmac<T>
Produces a hash from the current state of a given engine.
§fn to_byte_array(self) -> <Hmac<T> as Hash>::Bytes
fn to_byte_array(self) -> <Hmac<T> as Hash>::Bytes
Returns the underlying byte array.
§fn as_byte_array(&self) -> &<Hmac<T> as Hash>::Bytes
fn as_byte_array(&self) -> &<Hmac<T> as Hash>::Bytes
Returns a reference to the underlying byte array.
§fn from_byte_array(bytes: <T as Hash>::Bytes) -> Hmac<T>
fn from_byte_array(bytes: <T as Hash>::Bytes) -> Hmac<T>
Constructs a hash from the underlying byte array.
§const DISPLAY_BACKWARD: bool = false
const DISPLAY_BACKWARD: bool = false
Flag indicating whether user-visible serializations of this hash
should be backward. For some reason Satoshi decided this should be
true for
Sha256dHash, so here we are.§impl<T> Ord for Hmac<T>where
T: Ord + Hash,
impl<T> Ord for Hmac<T>where T: Ord + Hash,
§impl<T> PartialOrd<Hmac<T>> for Hmac<T>where
T: PartialOrd<T> + Hash,
impl<T> PartialOrd<Hmac<T>> for Hmac<T>where T: PartialOrd<T> + Hash,
§fn partial_cmp(&self, other: &Hmac<T>) -> Option<Ordering>
fn partial_cmp(&self, other: &Hmac<T>) -> Option<Ordering>
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 more§impl<T> Serialize for Hmac<T>where
T: Hash + Serialize,
impl<T> Serialize for Hmac<T>where T: Hash + Serialize,
§fn serialize<S>(
&self,
s: S
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where
S: Serializer,
fn serialize<S>( &self, s: S ) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl<T> Copy for Hmac<T>where T: Copy + Hash,
impl<T> Eq for Hmac<T>where T: Eq + Hash,
impl<T> StructuralEq for Hmac<T>where T: Hash,
impl<T> StructuralPartialEq for Hmac<T>where T: Hash,
Auto Trait Implementations§
impl<T> RefUnwindSafe for Hmac<T>where T: RefUnwindSafe,
impl<T> Send for Hmac<T>where T: Send,
impl<T> Sync for Hmac<T>where T: Sync,
impl<T> Unpin for Hmac<T>where T: Unpin,
impl<T> UnwindSafe for Hmac<T>where T: UnwindSafe,
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
source§impl<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,
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.