pub enum PostingsError {
Truncated {
needed: usize,
available: usize,
},
BadMagic,
UnsupportedVersion {
found: u16,
},
BitWidthTooLarge {
bits: u8,
},
ZeroBlockSize,
DocidsNotAscending {
docid: u32,
},
PositionsNotAscending {
position: u32,
},
ZeroTermFrequency,
InconsistentPostingCount {
declared: u32,
described: u32,
},
}Expand description
A rejected or malformed posting stream.
Variants§
Truncated
The byte stream ended inside a structure.
BadMagic
The leading magic did not match.
UnsupportedVersion
The declared version is not readable.
BitWidthTooLarge
A declared bit width exceeded 32.
ZeroBlockSize
The block size in the header was zero.
DocidsNotAscending
Document identifiers were not strictly ascending.
PositionsNotAscending
Positions within one posting were not strictly ascending.
ZeroTermFrequency
A term frequency was zero, which cannot occur in a posting list.
InconsistentPostingCount
The stream declared more postings than its blocks can hold.
Trait Implementations§
Source§impl Clone for PostingsError
impl Clone for PostingsError
impl Copy for PostingsError
Source§impl Debug for PostingsError
impl Debug for PostingsError
Source§impl Display for PostingsError
impl Display for PostingsError
impl Eq for PostingsError
Source§impl Error for PostingsError
impl Error for PostingsError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl From<PostingsError> for IndexError
impl From<PostingsError> for IndexError
Source§fn from(error: PostingsError) -> Self
fn from(error: PostingsError) -> Self
Converts to this type from the input type.
Source§impl From<PostingsError> for SealedSegmentError
impl From<PostingsError> for SealedSegmentError
Source§fn from(error: PostingsError) -> Self
fn from(error: PostingsError) -> Self
Converts to this type from the input type.
Source§impl PartialEq for PostingsError
impl PartialEq for PostingsError
impl StructuralPartialEq for PostingsError
Auto Trait Implementations§
impl Freeze for PostingsError
impl RefUnwindSafe for PostingsError
impl Send for PostingsError
impl Sync for PostingsError
impl Unpin for PostingsError
impl UnsafeUnpin for PostingsError
impl UnwindSafe for PostingsError
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