pub struct LineParsingOptions {
pub max_line_length: NumBytes,
pub overflow_behavior: LineOverflowBehavior,
}Expand description
Configuration options for parsing lines from a stream.
Fields§
§max_line_length: NumBytesMaximum length of a single line in bytes. When reached, further data won’t be appended to the current line. The line will be emitted in its current state.
A value of 0 means that “no limit” is imposed.
Only set this to 0 when you absolutely trust the input stream! Remember that an observed
stream maliciously writing endless amounts of data without ever writing a line break
would starve this system from ever emitting a line and will lead to an infinite amount of
memory being allocated to hold the line data, letting this process running out of memory!
Defaults to 16 kilobytes.
overflow_behavior: LineOverflowBehaviorWhat should happen when a line is too long?
Trait Implementations§
Source§impl Clone for LineParsingOptions
impl Clone for LineParsingOptions
Source§fn clone(&self) -> LineParsingOptions
fn clone(&self) -> LineParsingOptions
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 LineParsingOptions
impl Debug for LineParsingOptions
Source§impl Default for LineParsingOptions
impl Default for LineParsingOptions
Source§impl PartialEq for LineParsingOptions
impl PartialEq for LineParsingOptions
impl Copy for LineParsingOptions
impl Eq for LineParsingOptions
impl StructuralPartialEq for LineParsingOptions
Auto Trait Implementations§
impl Freeze for LineParsingOptions
impl RefUnwindSafe for LineParsingOptions
impl Send for LineParsingOptions
impl Sync for LineParsingOptions
impl Unpin for LineParsingOptions
impl UnwindSafe for LineParsingOptions
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