pub struct MaxLineLength { /* private fields */ }
Expand description
Max line length counter for UTF-8 encoded byte slices
use wz_core::Counter;
use wz_utf8::MaxLineLength;
let counter = MaxLineLength::with_linebreak(b'\n');
Implementations§
Source§impl MaxLineLength
impl MaxLineLength
Sourcepub fn with_linebreak(line_break: u8) -> Self
pub fn with_linebreak(line_break: u8) -> Self
Creates a new MaxLineLength counter that looks for line_break bytes
Sourcepub fn carriage_return() -> Self
pub fn carriage_return() -> Self
Creates a new MaxLineLength counter that looks for ‘\r’
Trait Implementations§
Source§impl Clone for MaxLineLength
impl Clone for MaxLineLength
Source§fn clone(&self) -> MaxLineLength
fn clone(&self) -> MaxLineLength
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<T> Counter<T> for MaxLineLengthwhere
T: MaxLineLengthCollector,
impl<T> Counter<T> for MaxLineLengthwhere
T: MaxLineLengthCollector,
Auto Trait Implementations§
impl Freeze for MaxLineLength
impl RefUnwindSafe for MaxLineLength
impl Send for MaxLineLength
impl Sync for MaxLineLength
impl Unpin for MaxLineLength
impl UnwindSafe for MaxLineLength
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