Package org.ametys.cms.search.query
Class FullTextQuery
java.lang.Object
org.ametys.cms.search.query.FullTextQuery
- All Implemented Interfaces:
Query
A
Query
realizing a full-text search on contents (search on all properties).
Available operators:- SEARCH (default)
- SEARCH_STEMMED
- LIKE
- EQ
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.ametys.cms.search.query.Query
Query.LogicalOperator, Query.Operator
-
Field Summary
Modifier and TypeFieldDescriptionprotected String
The field name.protected String
The language.protected Query.Operator
The operator.protected String
The value to test.protected boolean
true
if the value is already escaped and there is no need to escape again the value duringthe build of the query
.Fields inherited from interface org.ametys.cms.search.query.Query
BOOL_FILTER, BOOL_MUST, BOOL_MUST_NOT, BOOL_SHOULD
-
Constructor Summary
ConstructorDescriptionFullTextQuery
(String value) Build a FullTextQuery.FullTextQuery
(String value, String language) Build a FullTextQuery.FullTextQuery
(String value, String fieldName, String language, Query.Operator operator) Build a FullTextQuery.FullTextQuery
(String value, String fieldName, String language, Query.Operator operator, boolean alreadyEscaped) Build a FullTextQuery.FullTextQuery
(String value, String language, Query.Operator operator) Build a FullTextQuery.FullTextQuery
(String value, String language, Query.Operator operator, boolean alreadyEscaped) Build a FullTextQuery.FullTextQuery
(String value, Query.Operator operator) Build a FullTextQuery. -
Method Summary
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.ametys.cms.search.query.Query
buildAsJson, rewrite, toString
-
Field Details
-
_value
The value to test. -
_fieldName
The field name. -
_language
The language. -
_operator
The operator. -
_valueAlreadyEscaped
true
if the value is already escaped and there is no need to escape again the value duringthe build of the query
.
-
-
Constructor Details
-
FullTextQuery
Build a FullTextQuery.- Parameters:
value
- the value.
-
FullTextQuery
Build a FullTextQuery.- Parameters:
value
- the value.operator
- The operator to use.
-
FullTextQuery
Build a FullTextQuery.- Parameters:
value
- the value.language
- the language.
-
FullTextQuery
Build a FullTextQuery.- Parameters:
value
- the value.language
- the language.operator
- The operator to use.
-
FullTextQuery
public FullTextQuery(String value, String language, Query.Operator operator, boolean alreadyEscaped) Build a FullTextQuery.- Parameters:
value
- the value.language
- the language.operator
- The operator to use.alreadyEscaped
- true if the value is already escaped and there is no need to escape again the value duringthe build of the query
.
-
FullTextQuery
Build a FullTextQuery.- Parameters:
value
- the value.fieldName
- the field name.language
- the language.operator
- The operator to use.
-
FullTextQuery
public FullTextQuery(String value, String fieldName, String language, Query.Operator operator, boolean alreadyEscaped) Build a FullTextQuery.- Parameters:
value
- the value.fieldName
- the field name.language
- the language.operator
- The operator to use.alreadyEscaped
- true if the value is already escaped and there is no need to escape again the value duringthe build of the query
.
-
-
Method Details
-
getValue
Get the value.- Returns:
- the value.
-
getLanguage
Get the language.- Returns:
- the language.
-
getOperator
Get the operator to use.- Returns:
- the operator.
-
build
Description copied from interface:Query
Build the solr query string representing the Query object.- Specified by:
build
in interfaceQuery
- Returns:
- the solr query string representing the Query object.
- Throws:
QuerySyntaxException
- if the query can't be built because of a syntax error.
-
hashCode
-
equals
-