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

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

Introduction

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

Prototype

public boolean isIncludeUpper() 

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.  ja v a2s . c  o  m*/
        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());
        }
    }

}