public class TwigQuery extends AbstractNodeQuery
mapper| Constructor and Description |
|---|
TwigQuery(org.codehaus.jackson.map.ObjectMapper mapper,
KeywordQueryParser parser) |
| Modifier and Type | Method and Description |
|---|---|
TwigQuery |
optional(AbstractNodeQuery child)
Adds a child clause with a
NodeBooleanClause.Occur#SHOULD operator. |
TwigQuery |
optional(AbstractNodeQuery descendant,
int level)
Adds a descendant clause with a
NodeBooleanClause.Occur#SHOULD operator. |
TwigQuery |
setBoost(float boost)
Sets the boost for this query.
|
TwigQuery |
setLevel(int level)
Sets the node level constraint.
|
TwigQuery |
setRange(int lowerBound,
int upperBound)
Sets the node range constraint.
|
org.apache.lucene.search.Query |
toQuery(boolean proxy)
Convert the constructed query into a
Query. |
TwigQuery |
with(AbstractNodeQuery child)
Adds a child clause with a
NodeBooleanClause.Occur#MUST operator. |
TwigQuery |
with(AbstractNodeQuery descendant,
int level)
Adds a descendant clause with a
NodeBooleanClause.Occur#MUST operator. |
TwigQuery |
without(AbstractNodeQuery child)
Adds a child clause with a
NodeBooleanClause.Occur#MUST_NOT operator. |
TwigQuery |
without(AbstractNodeQuery descendant,
int level)
Adds a descendant clause with a
NodeBooleanClause.Occur#MUST_NOT operator. |
getLevel, getLowerBound, getUpperBound, hasLevel, hasRangetoStringpublic TwigQuery(org.codehaus.jackson.map.ObjectMapper mapper,
KeywordQueryParser parser)
public TwigQuery setLevel(int level)
AbstractNodeQuerysetLevel in class AbstractNodeQueryorg.sindice.siren.search.node.NodeQuery#setLevelConstraint(int)}public TwigQuery setRange(int lowerBound, int upperBound)
AbstractNodeQuerysetRange in class AbstractNodeQueryorg.sindice.siren.search.node.NodeQuery#setNodeConstraint(int, int)}public TwigQuery setBoost(float boost)
AbstractQuerysetBoost in class AbstractQueryQuery#setBoost(float)}public TwigQuery with(AbstractNodeQuery child)
NodeBooleanClause.Occur#MUST operator.
Use this method for child clauses that must appear in the matching twigs.
NodeBooleanClause.Occur#MUST,
TwigQuery.addChild(NodeQuery, NodeBooleanClause.Occur)public TwigQuery with(AbstractNodeQuery descendant, int level)
NodeBooleanClause.Occur#MUST operator.
Use this method for descendant clauses that must appear in the matching twigs.
NodeBooleanClause.Occur#MUST,
TwigQuery.addDescendant(int, NodeQuery, NodeBooleanClause.Occur)public TwigQuery without(AbstractNodeQuery child)
NodeBooleanClause.Occur#MUST_NOT operator.
Use this method for child clauses that must not appear in the matching twigs.
NodeBooleanClause.Occur#MUST_NOT,
TwigQuery.addChild(NodeQuery, NodeBooleanClause.Occur)public TwigQuery without(AbstractNodeQuery descendant, int level)
NodeBooleanClause.Occur#MUST_NOT operator.
Use this method for descendant clauses that must not appear in the matching twigs.
NodeBooleanClause.Occur#MUST_NOT,
TwigQuery.addDescendant(int, NodeQuery, NodeBooleanClause.Occur)public TwigQuery optional(AbstractNodeQuery child)
NodeBooleanClause.Occur#SHOULD operator.
Use this method for child clauses that should appear in the matching twigs.
NodeBooleanClause.Occur#SHOULD,
TwigQuery.addChild(NodeQuery, NodeBooleanClause.Occur)public TwigQuery optional(AbstractNodeQuery descendant, int level)
NodeBooleanClause.Occur#SHOULD operator.
Use this method for descendant clauses that should appear in the matching twigs.
NodeBooleanClause.Occur#SHOULD,
TwigQuery.addDescendant(int, NodeQuery, NodeBooleanClause.Occur)public org.apache.lucene.search.Query toQuery(boolean proxy)
throws org.apache.lucene.queryparser.flexible.core.QueryNodeException
AbstractQueryQuery.toQuery in class AbstractNodeQueryproxy - Should the query be wrapped into a LuceneProxyNodeQuery ?org.apache.lucene.queryparser.flexible.core.QueryNodeExceptionCopyright © 2014. All rights reserved.