Trait rustc_data_structures::ToHex
[−]
[src]
pub trait ToHex {
fn to_hex(&self) -> String;
}🔬 This is a nightly-only experimental API. (rustc_private)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml instead?
A trait for converting a value to hexadecimal encoding
Required Methods
fn to_hex(&self) -> String
🔬 This is a nightly-only experimental API. (rustc_private)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml instead?
Converts the value of self to a hex value, returning the owned
string.
Implementations on Foreign Types
impl ToHex for [u8][src]
fn to_hex(&self) -> String[src]
🔬 This is a nightly-only experimental API. (rustc_private)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml instead?
Turn a vector of u8 bytes into a hexadecimal string.
Examples
#![feature(rustc_private)] extern crate serialize; use serialize::hex::ToHex; fn main () { let str = [52,32].to_hex(); println!("{}", str); }