Function libipld::cid::multibase::decode [−]
pub fn decode<T>(input: T) -> Result<(Base, Vec<u8, Global>), Error> where
T: AsRef<str>,
Expand description
Decode the base string.
Examples
use multibase::{Base, decode}; assert_eq!( decode("zCn8eVZg").unwrap(), (Base::Base58Btc, b"hello".to_vec()) );