pub enum CompareResult {
Ok(usize),
Incomplete,
Error,
}
Expand description
Result of Compare::compare
Variants§
Ok(usize)
Comparison was successful
usize
is the end of the successful match within the buffer.
This is most relevant for caseless UTF-8 where Compare::compare
’s parameter might be a different
length than the match within the buffer.
Incomplete
We need more data to be sure
Error
Comparison failed
Trait Implementations§
Source§impl Debug for CompareResult
impl Debug for CompareResult
Source§impl PartialEq for CompareResult
impl PartialEq for CompareResult
impl Eq for CompareResult
impl StructuralPartialEq for CompareResult
Auto Trait Implementations§
impl Freeze for CompareResult
impl RefUnwindSafe for CompareResult
impl Send for CompareResult
impl Sync for CompareResult
impl Unpin for CompareResult
impl UnwindSafe for CompareResult
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
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...)
attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 16 bytes
Size for each variant:
Ok
: 8 bytesIncomplete
: 0 bytesError
: 0 bytes