Struct aliri_base64::Base64UrlRef [−][src]
#[repr(transparent)]pub struct Base64UrlRef(_);
Borrowed data to be encoded as URL-safe base64 (no padding)
Encoding alphabet: A
–Z
, a
–z
, 0
–9
, -
, _
Data is borrowed in its raw form. Costs of converting to base64 form are only incurred when serializing or displaying the value.
Implementations
impl Base64UrlRef
[src]
impl Base64UrlRef
[src]pub fn from_slice(raw: &[u8]) -> &Self
[src]
Transparently reinterprets the slice as base64
pub fn from_mut_slice(raw: &mut [u8]) -> &mut Self
[src]
Transparently reinterprets the mutable slice as base64
pub const fn encoded_len(&self) -> usize
[src]
Calculates the expected length of the base64-encoding of this buffer
pub const fn as_slice(&self) -> &[u8]
[src]
Provides access to the underlying slice
pub fn as_mut_slice(&mut self) -> &mut [u8]
[src]
Provides mutable access to the underlying slice
Trait Implementations
impl AsRef<Base64UrlRef> for Base64Url
[src]
impl AsRef<Base64UrlRef> for Base64Url
[src]fn as_ref(&self) -> &Base64UrlRef
[src]
impl Borrow<Base64UrlRef> for Base64Url
[src]
impl Borrow<Base64UrlRef> for Base64Url
[src]fn borrow(&self) -> &Base64UrlRef
[src]
impl Eq for Base64UrlRef
[src]
impl Eq for Base64UrlRef
[src]impl From<&'_ Base64UrlRef> for Base64Url
[src]
impl From<&'_ Base64UrlRef> for Base64Url
[src]fn from(val: &Base64UrlRef) -> Self
[src]
impl Hash for Base64UrlRef
[src]
impl Hash for Base64UrlRef
[src]impl PartialEq<Base64Url> for Base64UrlRef
[src]
impl PartialEq<Base64Url> for Base64UrlRef
[src]impl PartialEq<Base64UrlRef> for Base64UrlRef
[src]
impl PartialEq<Base64UrlRef> for Base64UrlRef
[src]fn eq(&self, other: &Base64UrlRef) -> bool
[src]
fn ne(&self, other: &Base64UrlRef) -> bool
[src]
impl PartialEq<Base64UrlRef> for Base64Url
[src]
impl PartialEq<Base64UrlRef> for Base64Url
[src]impl Serialize for Base64UrlRef
[src]
impl Serialize for Base64UrlRef
[src]This is supported on crate feature
serde
only.Serialize the underlying byte array as a base64 string
impl StructuralEq for Base64UrlRef
[src]
impl StructuralEq for Base64UrlRef
[src]impl StructuralPartialEq for Base64UrlRef
[src]
impl StructuralPartialEq for Base64UrlRef
[src]Auto Trait Implementations
impl RefUnwindSafe for Base64UrlRef
impl RefUnwindSafe for Base64UrlRef
impl Send for Base64UrlRef
impl Send for Base64UrlRef
impl !Sized for Base64UrlRef
impl !Sized for Base64UrlRef
impl Sync for Base64UrlRef
impl Sync for Base64UrlRef
impl Unpin for Base64UrlRef
impl Unpin for Base64UrlRef
impl UnwindSafe for Base64UrlRef
impl UnwindSafe for Base64UrlRef