Package org.apache.lucene.queryparser.flexible.standard.nodes

Examples of org.apache.lucene.queryparser.flexible.standard.nodes.NumericRangeQueryNode


  }
 
  @Override
  public NumericRangeQuery<? extends Number> build(QueryNode queryNode)
      throws QueryNodeException {
    NumericRangeQueryNode numericRangeNode = (NumericRangeQueryNode) queryNode;
   
    NumericQueryNode lowerNumericNode = numericRangeNode.getLowerBound();
    NumericQueryNode upperNumericNode = numericRangeNode.getUpperBound();
   
    Number lowerNumber = lowerNumericNode.getValue();
    Number upperNumber = upperNumericNode.getValue();
   
    NumericConfig numericConfig = numericRangeNode.getNumericConfig();
    NumericType numberType = numericConfig.getType();
    String field = StringUtils.toString(numericRangeNode.getField());
    boolean minInclusive = numericRangeNode.isLowerInclusive();
    boolean maxInclusive = numericRangeNode.isUpperInclusive();
    int precisionStep = numericConfig.getPrecisionStep();
   
    switch (numberType) {
     
      case LONG:
View Full Code Here


            NumericQueryNode lowerNode = new NumericQueryNode(fieldNode
                .getField(), number, numberFormat);
            NumericQueryNode upperNode = new NumericQueryNode(fieldNode
                .getField(), number, numberFormat);
           
            return new NumericRangeQueryNode(lowerNode, upperNode, true, true,
                numericConfig);
           
          }
         
        }
View Full Code Here

                termRangeNode.getField(), upperNumber, numberFormat);
           
            boolean lowerInclusive = termRangeNode.isLowerInclusive();
            boolean upperInclusive = termRangeNode.isUpperInclusive();
           
            return new NumericRangeQueryNode(lowerNode, upperNode,
                lowerInclusive, upperInclusive, numericConfig);
           
          }
         
        }
View Full Code Here

TOP

Related Classes of org.apache.lucene.queryparser.flexible.standard.nodes.NumericRangeQueryNode

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.