Query.LogicalOperator, Query.Operator
Modifier and Type | Field and Description |
---|---|
protected Query |
_query
The negated query.
|
static String |
NEGATION_QUERY_PREFIX
The prefix for making a query negative.
|
Constructor and Description |
---|
NotQuery(Query query)
Build a NotQuery object.
|
Modifier and Type | Method and Description |
---|---|
static StringBuilder |
appendNegation(StringBuilder query)
Appends a negation to the query being built.
|
String |
build()
Build the solr query string representing the Query object.
|
boolean |
equals(Object obj) |
Query |
getQuery()
Get the negated query.
|
int |
hashCode() |
public static final String NEGATION_QUERY_PREFIX
public static StringBuilder appendNegation(StringBuilder query)
sb.append("*:* -");
query
- The query builderpublic String build() throws QuerySyntaxException
Query
build
in interface Query
QuerySyntaxException
- if the query can't be built because of a syntax error.