Enum base64ct::LineEnding
source · pub enum LineEnding {
CR,
LF,
CRLF,
}
Expand description
Line endings: variants of newline characters that can be used with Base64.
Use LineEnding::default
to get an appropriate line ending for the
current operating system.
Variants§
CR
Carriage return: \r
(Pre-OS X Macintosh)
LF
Line feed: \n
(Unix OSes)
CRLF
Carriage return + line feed: \r\n
(Windows)
Implementations§
source§impl LineEnding
impl LineEnding
sourcepub fn as_bytes(self) -> &'static [u8] ⓘ
pub fn as_bytes(self) -> &'static [u8] ⓘ
Get the byte serialization of this LineEnding
.
sourcepub fn len(self) -> usize
pub fn len(self) -> usize
Get the encoded length of this LineEnding
.
Trait Implementations§
source§impl Clone for LineEnding
impl Clone for LineEnding
source§fn clone(&self) -> LineEnding
fn clone(&self) -> LineEnding
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for LineEnding
impl Debug for LineEnding
source§impl Default for LineEnding
impl Default for LineEnding
source§fn default() -> LineEnding
fn default() -> LineEnding
Returns the “default value” for a type. Read more
source§impl Ord for LineEnding
impl Ord for LineEnding
source§fn cmp(&self, other: &LineEnding) -> Ordering
fn cmp(&self, other: &LineEnding) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq for LineEnding
impl PartialEq for LineEnding
source§impl PartialOrd for LineEnding
impl PartialOrd for LineEnding
impl Copy for LineEnding
impl Eq for LineEnding
impl StructuralPartialEq for LineEnding
Auto Trait Implementations§
impl Freeze for LineEnding
impl RefUnwindSafe for LineEnding
impl Send for LineEnding
impl Sync for LineEnding
impl Unpin for LineEnding
impl UnwindSafe for LineEnding
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<T> CloneToUninit for Twhere
T: Copy,
impl<T> CloneToUninit for Twhere
T: Copy,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)