Enum summavy::query::QueryParserError
source · pub enum QueryParserError {
Show 16 variants
SyntaxError(String),
UnsupportedQuery(String),
FieldDoesNotExist(String),
ExpectedInt(ParseIntError),
ExpectedBase64(DecodeError),
ExpectedFloat(ParseFloatError),
ExpectedBool(ParseBoolError),
AllButQueryForbidden,
NoDefaultFieldDeclared,
FieldNotIndexed(String),
FieldDoesNotHavePositionsIndexed(String),
UnknownTokenizer {
tokenizer: String,
field: String,
},
RangeMustNotHavePhrase,
DateFormatError(Parse),
FacetFormatError(FacetParseError),
IpFormatError(AddrParseError),
}
Expand description
Possible error that may happen when parsing a query.
Variants
SyntaxError(String)
Error in the query syntax
UnsupportedQuery(String)
This query is unsupported.
FieldDoesNotExist(String)
The query references a field that is not in the schema
ExpectedInt(ParseIntError)
The query contains a term for a u64
or i64
-field, but the value
is neither.
ExpectedBase64(DecodeError)
The query contains a term for a bytes field, but the value is not valid base64.
ExpectedFloat(ParseFloatError)
The query contains a term for a f64
-field, but the value
is not a f64.
ExpectedBool(ParseBoolError)
The query contains a term for a bool field, but the value is not a bool.
AllButQueryForbidden
It is forbidden queries that are only “excluding”. (e.g. -title:pop)
NoDefaultFieldDeclared
If no default field is declared, running a query without any field specified is forbbidden.
FieldNotIndexed(String)
The field searched for is not declared as indexed in the schema.
FieldDoesNotHavePositionsIndexed(String)
A phrase query was requested for a field that does not have any positions indexed.
UnknownTokenizer
The tokenizer for the given field is unknown The two argument strings are the name of the field, the name of the tokenizer
RangeMustNotHavePhrase
The query contains a range query with a phrase as one of the bounds. Only terms can be used as bounds.
DateFormatError(Parse)
The format for the date field is not RFC 3339 compliant.
FacetFormatError(FacetParseError)
The format for the facet field is invalid.
IpFormatError(AddrParseError)
The format for the ip field is invalid.
Trait Implementations
sourceimpl Debug for QueryParserError
impl Debug for QueryParserError
sourceimpl Display for QueryParserError
impl Display for QueryParserError
sourceimpl Error for QueryParserError
impl Error for QueryParserError
sourcefn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · sourcefn description(&self) -> &str
fn description(&self) -> &str
sourceimpl From<AddrParseError> for QueryParserError
impl From<AddrParseError> for QueryParserError
sourcefn from(source: AddrParseError) -> Self
fn from(source: AddrParseError) -> Self
sourceimpl From<DecodeError> for QueryParserError
impl From<DecodeError> for QueryParserError
sourcefn from(source: DecodeError) -> Self
fn from(source: DecodeError) -> Self
sourceimpl From<FacetParseError> for QueryParserError
impl From<FacetParseError> for QueryParserError
sourcefn from(source: FacetParseError) -> Self
fn from(source: FacetParseError) -> Self
sourceimpl From<Parse> for QueryParserError
impl From<Parse> for QueryParserError
sourceimpl From<ParseBoolError> for QueryParserError
impl From<ParseBoolError> for QueryParserError
sourcefn from(source: ParseBoolError) -> Self
fn from(source: ParseBoolError) -> Self
sourceimpl From<ParseFloatError> for QueryParserError
impl From<ParseFloatError> for QueryParserError
sourcefn from(source: ParseFloatError) -> Self
fn from(source: ParseFloatError) -> Self
sourceimpl From<ParseIntError> for QueryParserError
impl From<ParseIntError> for QueryParserError
sourcefn from(source: ParseIntError) -> Self
fn from(source: ParseIntError) -> Self
sourceimpl From<QueryParserError> for TantivyError
impl From<QueryParserError> for TantivyError
sourcefn from(parsing_error: QueryParserError) -> TantivyError
fn from(parsing_error: QueryParserError) -> TantivyError
sourceimpl PartialEq<QueryParserError> for QueryParserError
impl PartialEq<QueryParserError> for QueryParserError
sourcefn eq(&self, other: &QueryParserError) -> bool
fn eq(&self, other: &QueryParserError) -> bool
impl Eq for QueryParserError
impl StructuralEq for QueryParserError
impl StructuralPartialEq for QueryParserError
Auto Trait Implementations
impl RefUnwindSafe for QueryParserError
impl Send for QueryParserError
impl Sync for QueryParserError
impl Unpin for QueryParserError
impl UnwindSafe for QueryParserError
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
sourceimpl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
sourcefn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
. Read moresourcefn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
. Read moresourcefn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s. Read moresourcefn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s. Read more