mirror of
https://github.com/ebean-orm/ebean.git
synced 2024-04-21 10:51:47 +00:00
#1100 - Refactor OrmQueryPlanKey to use string expression for where
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
package io.ebeaninternal.server.expression;
|
||||
|
||||
import io.ebean.LikeType;
|
||||
import io.ebeaninternal.api.HashQueryPlanBuilder;
|
||||
import io.ebeaninternal.api.SpiExpression;
|
||||
import io.ebeaninternal.api.SpiExpressionRequest;
|
||||
import io.ebeaninternal.server.el.ElPropertyValue;
|
||||
@@ -50,9 +49,8 @@ class NativeILikeExpression extends AbstractExpression {
|
||||
* Based on caseInsensitive and the property name.
|
||||
*/
|
||||
@Override
|
||||
public void queryPlanHash(HashQueryPlanBuilder builder) {
|
||||
builder.add(NativeILikeExpression.class).add(propName);
|
||||
builder.bind(1);
|
||||
public void queryPlanHash(StringBuilder builder) {
|
||||
builder.append("NativeILike[").append(propName).append("]");
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -60,16 +58,6 @@ class NativeILikeExpression extends AbstractExpression {
|
||||
return val.hashCode();
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isSameByPlan(SpiExpression other) {
|
||||
if (!(other instanceof NativeILikeExpression)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
NativeILikeExpression that = (NativeILikeExpression) other;
|
||||
return this.propName.equals(that.propName);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isSameByBind(SpiExpression other) {
|
||||
NativeILikeExpression that = (NativeILikeExpression) other;
|
||||
|
||||
Reference in New Issue
Block a user