[][src]Trait bitcoin_cash::Hashed

pub trait Hashed: Display + Debug + Sized + Eq + PartialEq {
    fn digest(data: &[u8]) -> Self;
fn as_slice(&self) -> &[u8];
fn from_slice(hash: &[u8]) -> Result<Self>; fn from_hex_le(s: &str) -> Result<Self> { ... }
fn from_hex_be(s: &str) -> Result<Self> { ... }
fn to_hex_le(&self) -> String { ... }
fn to_hex_be(&self) -> String { ... } }

Required methods

fn digest(data: &[u8]) -> Self

fn as_slice(&self) -> &[u8]

fn from_slice(hash: &[u8]) -> Result<Self>

Loading content...

Provided methods

fn from_hex_le(s: &str) -> Result<Self>

fn from_hex_be(s: &str) -> Result<Self>

fn to_hex_le(&self) -> String

fn to_hex_be(&self) -> String

Loading content...

Implementors

impl Hashed for Hash160[src]

impl Hashed for Ripemd160[src]

impl Hashed for Sha1[src]

impl Hashed for Sha256[src]

impl Hashed for Sha256d[src]

Loading content...