#1214 - ENH: Add inPairs() expression - support L2 cache hits for complex natural key with findList() and in pairs expression

This commit is contained in:
Rob Bygrave
2017-11-19 16:47:32 +13:00
parent f0ddf6c7e6
commit ef91c643ed
22 changed files with 765 additions and 87 deletions
@@ -6,6 +6,7 @@ import io.ebean.ExpressionFactory;
import io.ebean.ExpressionList;
import io.ebean.Junction;
import io.ebean.LikeType;
import io.ebean.Pairs;
import io.ebean.Query;
import io.ebean.bean.EntityBean;
import io.ebean.search.Match;
@@ -361,6 +362,14 @@ public class DefaultExpressionFactory implements SpiExpressionFactory {
return new LikeExpression(propertyName, value, true, LikeType.CONTAINS);
}
/**
* In - property has a value in the collection of values.
*/
@Override
public Expression inPairs(Pairs pairs) {
return new InPairsExpression(pairs, false);
}
/**
* In - property has a value in the array of values.
*/