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§
source§impl Debug for QueryParserError
impl Debug for QueryParserError
source§impl Display for QueryParserError
impl Display for QueryParserError
source§impl Error for QueryParserError
impl Error for QueryParserError
source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · source§fn description(&self) -> &str
fn description(&self) -> &str
source§impl From<AddrParseError> for QueryParserError
impl From<AddrParseError> for QueryParserError
source§fn from(source: AddrParseError) -> Self
fn from(source: AddrParseError) -> Self
source§impl From<DecodeError> for QueryParserError
impl From<DecodeError> for QueryParserError
source§fn from(source: DecodeError) -> Self
fn from(source: DecodeError) -> Self
source§impl From<FacetParseError> for QueryParserError
impl From<FacetParseError> for QueryParserError
source§fn from(source: FacetParseError) -> Self
fn from(source: FacetParseError) -> Self
source§impl From<Parse> for QueryParserError
impl From<Parse> for QueryParserError
source§impl From<ParseBoolError> for QueryParserError
impl From<ParseBoolError> for QueryParserError
source§fn from(source: ParseBoolError) -> Self
fn from(source: ParseBoolError) -> Self
source§impl From<ParseFloatError> for QueryParserError
impl From<ParseFloatError> for QueryParserError
source§fn from(source: ParseFloatError) -> Self
fn from(source: ParseFloatError) -> Self
source§impl From<ParseIntError> for QueryParserError
impl From<ParseIntError> for QueryParserError
source§fn from(source: ParseIntError) -> Self
fn from(source: ParseIntError) -> Self
source§impl From<QueryParserError> for TantivyError
impl From<QueryParserError> for TantivyError
source§fn from(parsing_error: QueryParserError) -> TantivyError
fn from(parsing_error: QueryParserError) -> TantivyError
source§impl PartialEq<QueryParserError> for QueryParserError
impl PartialEq<QueryParserError> for QueryParserError
source§fn 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§
source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
source§fn 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 moresource§fn 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 moresource§fn 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 moresource§fn 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