Search in sources :

Example 21 with IntItem

use of com.yahoo.prelude.query.IntItem in project vespa by vespa-engine.

the class ParseTestCase method testSmallerNumericWithIndex.

@Test
public void testSmallerNumericWithIndex() {
    IntItem item = (IntItem) tester.assertParsed("score:>454", "score:>454", Query.Type.ANY);
    assertEquals("score", item.getIndexName());
    assertEquals(454L, item.getFromLimit().number());
    assertFalse(item.getFromLimit().isInclusive());
}
Also used : IntItem(com.yahoo.prelude.query.IntItem) Test(org.junit.Test)

Aggregations

IntItem (com.yahoo.prelude.query.IntItem)21 Test (org.junit.Test)12 AndItem (com.yahoo.prelude.query.AndItem)11 Item (com.yahoo.prelude.query.Item)9 NonNull (edu.umd.cs.findbugs.annotations.NonNull)7 CompositeItem (com.yahoo.prelude.query.CompositeItem)5 WordItem (com.yahoo.prelude.query.WordItem)5 Query (com.yahoo.search.Query)5 NotItem (com.yahoo.prelude.query.NotItem)4 OrItem (com.yahoo.prelude.query.OrItem)4 PhraseItem (com.yahoo.prelude.query.PhraseItem)4 PhraseSegmentItem (com.yahoo.prelude.query.PhraseSegmentItem)4 PrefixItem (com.yahoo.prelude.query.PrefixItem)4 RankItem (com.yahoo.prelude.query.RankItem)4 SubstringItem (com.yahoo.prelude.query.SubstringItem)4 SuffixItem (com.yahoo.prelude.query.SuffixItem)4 RangeItem (com.yahoo.prelude.query.RangeItem)2 LazyMap (com.yahoo.collections.LazyMap)1 AndSegmentItem (com.yahoo.prelude.query.AndSegmentItem)1 DotProductItem (com.yahoo.prelude.query.DotProductItem)1