Example usage for org.apache.solr.search.function ValueSourceRangeFilter getLowerVal

List of usage examples for org.apache.solr.search.function ValueSourceRangeFilter getLowerVal

Introduction

In this page you can find the example usage for org.apache.solr.search.function ValueSourceRangeFilter getLowerVal.

Prototype

public String getLowerVal() 

Source Link

Usage

From source file:org.vootoo.search.CollectorFilterablePluginTest.java

License:Apache License

private void assertRange(String range, String min, String max, boolean incMin, boolean incMax, boolean error) {
    try {//  w  w w  .  j  a  v  a 2 s . c om
        ValueSourceRangeFilter vsrf = CollectorFilterablePlugin.parseRange(null, range);
        if (error) {
            Assert.fail("parse v=" + range + " ok, but need error");
        }
        Assert.assertNotNull(vsrf);
        Assert.assertEquals(vsrf.getLowerVal(), min);
        Assert.assertEquals(vsrf.getUpperVal(), max);
        Assert.assertEquals(vsrf.isIncludeLower(), incMin);
        Assert.assertEquals(vsrf.isIncludeUpper(), incMax);
    } catch (SyntaxError e) {
        if (!error) {
            Assert.fail("parse v=" + range + " error, " + e.getMessage());
        }
    }

}