pub struct EscapedStr(/* private fields */);Expand description
A slice buffer which is in an escaped format: containing possible 0u8 and 1u8 bytes escaped with a 1u8 as well as a final terminating null byte
Implementations§
Source§impl EscapedStr
impl EscapedStr
Sourcepub unsafe fn from_str(b: &str) -> &EscapedStr
pub unsafe fn from_str(b: &str) -> &EscapedStr
Sourcepub fn as_bytes(&self) -> &[u8] ⓘ
pub fn as_bytes(&self) -> &[u8] ⓘ
Returns the raw underlying byte representation of the escaped string, including escaped bytes.
pub fn as_slice(&self) -> &EscapedSlice
Sourcepub fn chars(&self) -> EscapedChars<'_> ⓘ
pub fn chars(&self) -> EscapedChars<'_> ⓘ
Returns a iterator over the characters in this string, unescaping escaped characters.