Function display_bytes::display_bytes_string [−][src]
pub fn display_bytes_string(bytes: &[u8]) -> Cow<str>
Attempt to convert the byte slice to a string, or else format it to a string using the default
DisplayBytesConfig
.
All string-decodable sequences of useful length will be displayed as they are, and all non-decodable byte sequences will be printed in a human-readable format.
The format is unspecified. If you want to specify a format, use DisplayBytesConfig
directly
or one of the statics in the crate root.