#1943 - Return ExpressionList<T> from setMaxRows() setFirstRow() to allow fluid style

This is to allow fluid style use of setMaxRows() setFirstRow() with filterMany query
This commit is contained in:
rob bygrave
2020-02-17 17:19:27 +13:00
parent 1dd0f3cbf8
commit e0d322d80a
7 changed files with 79 additions and 21 deletions
@@ -196,7 +196,7 @@ public class TestQueryFindIterate extends BaseTestCase {
Query<Customer> query = server.find(Customer.class)
.setAutoTune(false)
.where().gt("id", "JUNK_NOT_A_LONG")
.setMaxRows(2);
.setMaxRows(2).query();
// this throws an exception immediately
query.findEach(bean -> {
@@ -221,7 +221,7 @@ public class TestQueryFindIterate extends BaseTestCase {
Query<Customer> query = server.find(Customer.class)
.setAutoTune(false)
.where().gt("id", 0)
.setMaxRows(2);
.setMaxRows(2).query();
query.findEach(customer -> {
if (customer != null) {