Package org.apache.lucene.messages

Examples of org.apache.lucene.messages.MessageImpl


          try {
            bQuery.add(query, getModifierValue(child));
          } catch (TooManyClauses ex) {

            throw new QueryNodeException(new MessageImpl(
                QueryParserMessages.TOO_MANY_BOOLEAN_CLAUSES, new Object[]{BooleanQuery
                    .getMaxClauseCount(), queryNode
                    .toQueryString(new EscapeQuerySyntaxImpl())}), ex);

          }
View Full Code Here


          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);

View Full Code Here

  /**
   * This QueryNode is used to identify parenthesis on the original query string
   */
  public GroupQueryNode(QueryNode query) {
    if (query == null) {
      throw new QueryNodeError(new MessageImpl(
          QueryParserMessages.PARAMETER_VALUE_NOT_SUPPORTED, new Object[]{"query", "null"}));
    }

    allocate();
    setLeaf(false);
View Full Code Here

   *              throw in overridden method to disallow
   */
  public PhraseSlopQueryNode(QueryNode query, int value)
      throws QueryNodeException {
    if (query == null) {
      throw new QueryNodeError(new MessageImpl(
          QueryParserMessages.NODE_ACTION_NOT_SUPPORTED, new Object[]{"query", "null"}));
    }

    this.value = value;
    setLeaf(false);
View Full Code Here

    this.proximityType = type;
    this.inorder = inorder;
    this.field = field;
    if (type == Type.NUMBER) {
      if (distance <= 0) {
        throw new QueryNodeError(new MessageImpl(
            QueryParserMessages.PARAMETER_VALUE_NOT_SUPPORTED, new Object[]{"distance",
            distance}));

      } else {
        this.distance = distance;
View Full Code Here

   *
   * @throws QueryNodeException
   */
  public BoostQueryNode(QueryNode query, float value) throws QueryNodeException {
    if (query == null) {
      throw new QueryNodeError(new MessageImpl(
          QueryParserMessages.NODE_ACTION_NOT_SUPPORTED, new Object[]{"query", "null"}));
    }

    this.value = value;
    setLeaf(false);
View Full Code Here

    super(message, throwable);
  }

  public void setQuery(CharSequence query) {
    this.query = query;
    this.message = new MessageImpl(
        QueryParserMessages.INVALID_SYNTAX_CANNOT_PARSE, new Object[] {query, ""});
  }
View Full Code Here

   * @param value
   *          - slop value
   */
  public SlopQueryNode(QueryNode query, int value) {
    if (query == null) {
      throw new QueryNodeError(new MessageImpl(
          QueryParserMessages.NODE_ACTION_NOT_SUPPORTED, new Object[]{"query", "null"}));
    }

    this.value = value;
    setLeaf(false);
View Full Code Here

   * @param mod
   *          - Modifier Value
   */
  public ModifierQueryNode(QueryNode query, Modifier mod) {
    if (query == null) {
      throw new QueryNodeError(new MessageImpl(
          QueryParserMessages.PARAMETER_VALUE_NOT_SUPPORTED, new Object[]{"query", "null"}));
    }

    allocate();
    setLeaf(false);
View Full Code Here

   * type with the fields "currentToken", "expectedTokenSequences", and
   * "tokenImage" set.
   */
  public ParseException(Token currentTokenVal,
      int[][] expectedTokenSequencesVal, String[] tokenImageVal) {
    super(new MessageImpl(QueryParserMessages.INVALID_SYNTAX, new Object[]{initialise(
        currentTokenVal, expectedTokenSequencesVal, tokenImageVal)}));
    this.currentToken = currentTokenVal;
    this.expectedTokenSequences = expectedTokenSequencesVal;
    this.tokenImage = tokenImageVal;
  }
View Full Code Here

TOP

Related Classes of org.apache.lucene.messages.MessageImpl

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.