@Test public void testWithAggregationsAndFilter() throws Exception { ReflectivePredicateEvaluator evaluator = new ReflectivePredicateEvaluator( "SELECT sum(anInt) = 5 FROM myInterface WHERE aString = 'foo'", MyInterface.class); Assert.assertFalse(evaluator.evaluate(new MyImplementation(1, "foo"))); Assert.assertTrue(evaluator.evaluate(new MyImplementation(1, "foo"), new MyImplementation(4, "foo"), new MyImplementation(4, "bar"))); Assert.assertFalse(evaluator.evaluate(new MyImplementation(1, "foo"), new MyImplementation(4, "foo"), new MyImplementation(4, "foo"))); }
public boolean evaluate(Object... objects) throws SQLException{ return evaluate(Lists.newArrayList(objects), null); }
ReflectivePredicateEvaluator implements Closeable { public boolean evaluate(Object... objects) throws SQLException{ return evaluate(Lists.newArrayList(objects), null); } }
ReflectivePredicateEvaluator implements Closeable { public boolean evaluate(Object... objects) throws SQLException{ return evaluate(Lists.newArrayList(objects), null); } ReflectivePredicateEvaluator(String sql, Class<?>... referenceInterfaces); }
ReflectivePredicateEvaluator implements Closeable { public boolean evaluate(Object... objects) throws SQLException{ return evaluate(Lists.newArrayList(objects), null); } ReflectivePredicateEvaluator(String sql, Class<?>... referenceInterfaces); boolean evaluate(Object... objects); boolean evaluate(String sql, Object... objects); boolean evaluate(List<Object> objects); boolean evaluate(List<Object> objects, String sql); @Override void close(); }
ReflectivePredicateEvaluator implements Closeable { public boolean evaluate(Object... objects) throws SQLException{ return evaluate(Lists.newArrayList(objects), null); } ReflectivePredicateEvaluator(String sql, Class<?>... referenceInterfaces); boolean evaluate(Object... objects); boolean evaluate(String sql, Object... objects); boolean evaluate(List<Object> objects); boolean evaluate(List<Object> objects, String sql); @Override void close();  }