pub struct Decoder { /* private fields */ }Expand description
Middleware that decodes a string property using a specified encoding.
Implementations§
Source§impl Decoder
impl Decoder
Sourcepub fn decode_base64(&self, encoded: &str) -> Result<String, String>
pub fn decode_base64(&self, encoded: &str) -> Result<String, String>
Decodes a base64 encoded string.
Sourcepub fn decode_base64url(&self, encoded: &str) -> Result<String, String>
pub fn decode_base64url(&self, encoded: &str) -> Result<String, String>
Decodes a base64url encoded string.
Sourcepub fn decode_hex(&self, encoded: &str) -> Result<String, String>
pub fn decode_hex(&self, encoded: &str) -> Result<String, String>
Decodes a hex encoded string.
Trait Implementations§
Source§impl SourceMiddleware for Decoder
impl SourceMiddleware for Decoder
fn process<'life0, 'life1, 'async_trait>(
&'life0 self,
source_change: SourceChange,
_element_index: &'life1 dyn ElementIndex,
) -> Pin<Box<dyn Future<Output = Result<Vec<SourceChange>, MiddlewareError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Auto Trait Implementations§
impl Freeze for Decoder
impl RefUnwindSafe for Decoder
impl Send for Decoder
impl Sync for Decoder
impl Unpin for Decoder
impl UnsafeUnpin for Decoder
impl UnwindSafe for Decoder
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