This exception should be thrown if something wrong happens when dealing with {@link QueryNode}s.
It also supports NLS messages.
6566676869707172737475
try { bQuery.add(query, getModifierValue(child)); } catch (TooManyClauses ex) { throw new QueryNodeException(new MessageImpl( QueryParserMessages.TOO_MANY_BOOLEAN_CLAUSES, BooleanQuery .getMaxClauseCount(), queryNode .toQueryString(new EscapeQuerySyntaxImpl())), ex); }
81828384858687888990
return NumericRangeQuery.newDoubleRange(field, precisionStep, (Double) lowerNumber, (Double) upperNumber, minInclusive, maxInclusive); default : throw new QueryNodeException(new MessageImpl( QueryParserMessages.UNSUPPORTED_NUMERIC_DATA_TYPE, numberType)); } }
3839404142434445464748
@Override public MatchAllDocsQuery build(QueryNode queryNode) throws QueryNodeException { // validates node if (!(queryNode instanceof MatchAllDocsQueryNode)) { throw new QueryNodeException(new MessageImpl( QueryParserMessages.LUCENE_QUERY_CONVERSION_ERROR, queryNode .toQueryString(new EscapeQuerySyntaxImpl()), queryNode.getClass() .getName())); }
@Override public BooleanQuery build(QueryNode queryNode) throws QueryNodeException { // validates node if (!(queryNode instanceof MatchNoDocsQueryNode)) { throw new QueryNodeException(new MessageImpl( QueryParserMessages.LUCENE_QUERY_CONVERSION_ERROR, queryNode .toQueryString(new EscapeQuerySyntaxImpl()), queryNode.getClass() .getName())); }
6667686970717273747576
5758596061626364656667
try { bQuery.add(query, BooleanClause.Occur.SHOULD); } catch (TooManyClauses ex) { throw new QueryNodeException(new MessageImpl( /* * IQQQ.Q0028E_TOO_MANY_BOOLEAN_CLAUSES, * BooleanQuery.getMaxClauseCount() */QueryParserMessages.EMPTY_MESSAGE), ex);
5152535455565758596061
@Override protected QueryNode preProcessNode(QueryNode node) throws QueryNodeException { if (!((node instanceof BooleanQueryNode && !(node instanceof AndQueryNode)) || node .getClass() == FieldQueryNode.class)) { throw new QueryNodeException(new MessageImpl( QueryParserMessages.NODE_ACTION_NOT_SUPPORTED)); } return node;
7374757677787980818283
return node; switch (wildcardNode.getText().charAt(0)) { case '*': case '?': throw new QueryNodeException(new MessageImpl( QueryParserMessages.LEADING_WILDCARD_NOT_ALLOWED, node .toQueryString(new EscapeQuerySyntaxImpl()))); } }
6263646566676869707172
} else if (number instanceof Double) { return NumericType.DOUBLE; } else if (number instanceof Float) { return NumericType.FLOAT; } else { throw new QueryNodeException( new MessageImpl( QueryParserMessages.NUMBER_CLASS_NOT_SUPPORTED_BY_NUMERIC_RANGE_QUERY, number.getClass())); }
174175176177178179180181182183184
private void processNode(QueryNode node, QueryBuilder builder) throws QueryNodeException { if (builder == null) { throw new QueryNodeException(new MessageImpl( QueryParserMessages.LUCENE_QUERY_CONVERSION_ERROR, node .toQueryString(new EscapeQuerySyntaxImpl()), node.getClass() .getName())); }