pub enum Codec {
Base64,
Url,
Hex,
}Expand description
A text encoding for Action::Encode and Action::Decode.
Variants§
Base64
Base64 (RFC 4648) with the standard alphabet and = padding.
Decoding also takes the URL-safe alphabet (-, _), missing
padding, and spaces or line breaks anywhere.
Url
Percent-encoding (RFC 3986): every byte but A–Z, a–z,
0–9, -, ., _ and ~ becomes %XX. Decoding leaves +
alone.
Hex
Two hex digits per byte (Notepad++’s Converter, ASCII -> HEX). Decoding takes either case, and spaces or line breaks anywhere.
Implementations§
Trait Implementations§
impl Copy for Codec
Source§impl<'de> Deserialize<'de> for Codec
impl<'de> Deserialize<'de> for Codec
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for Codec
impl StructuralPartialEq for Codec
Auto Trait Implementations§
impl Freeze for Codec
impl RefUnwindSafe for Codec
impl Send for Codec
impl Sync for Codec
impl Unpin for Codec
impl UnsafeUnpin for Codec
impl UnwindSafe for Codec
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more