[][src]Struct hashed::Hashed

#[repr(transparent)]
pub struct Hashed<T: ?Sized + Hash> { /* fields omitted */ }

Methods

impl<T: ?Sized + Hash> Hashed<T>[src]

pub fn new(hashee: &T) -> Self[src]

Create a new Hashed from &T. Note that this function doesn't consume the input, so if it is later modified the hash will not update. To stop these kinds of errors, it is recommended to use the From or Into traits instead of this function whenever possible.

pub fn value(&self) -> u64[src]

Get the actual hash value the Hashed is wrapping.

Trait Implementations

impl<T: Clone + ?Sized + Hash> Clone for Hashed<T>[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl<T: Hash> From<T> for Hashed<T>[src]

impl<T: ?Sized + Hash> Into<u64> for Hashed<T>[src]

impl<T: PartialEq + ?Sized + Hash> PartialEq<Hashed<T>> for Hashed<T>[src]

impl<T: Copy + ?Sized + Hash> Copy for Hashed<T>[src]

impl<T: Eq + ?Sized + Hash> Eq for Hashed<T>[src]

impl<T: ?Sized + Hash> Debug for Hashed<T>[src]

impl<T: Hash + ?Sized> Hash for Hashed<T>[src]

fn hash_slice<H>(data: &[Self], state: &mut H) where
    H: Hasher
1.3.0[src]

Feeds a slice of this type into the given [Hasher]. Read more

Auto Trait Implementations

impl<T: ?Sized> Sync for Hashed<T> where
    T: Sync

impl<T: ?Sized> Send for Hashed<T> where
    T: Send

impl<T: ?Sized> Unpin for Hashed<T> where
    T: Unpin

impl<T: ?Sized> RefUnwindSafe for Hashed<T> where
    T: RefUnwindSafe

impl<T: ?Sized> UnwindSafe for Hashed<T> where
    T: UnwindSafe

Blanket Implementations

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

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

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

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<T> BorrowMut<T> for T where
    T: ?Sized
[src]

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

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