#1546 - Refactor: Swap from entityBean._ebean_intercept() to entityBean._ebean_getIntercept()

This commit is contained in:
rob bygrave
2018-11-13 23:50:13 +13:00
parent 54a4fd75f1
commit 4bd3a0f293
2 changed files with 3 additions and 3 deletions
@@ -66,7 +66,7 @@ public class CachedBeanDataFromBean {
Object v = aPropertiesNonTransient.getValue(bean);
aPropertiesNonTransient.setValue(sharableBean, v);
}
EntityBeanIntercept intercept = sharableBean._ebean_intercept();
EntityBeanIntercept intercept = sharableBean._ebean_getIntercept();
intercept.setReadOnly(true);
intercept.setLoaded();
return sharableBean;
@@ -2351,7 +2351,7 @@ public final class DefaultServer implements SpiServer, SpiEbeanServer {
}
Object id = idProperty.getVal(entityBean);
if (entityBean._ebean_intercept().isNew() && id != null) {
if (entityBean._ebean_getIntercept().isNew() && id != null) {
// Primary Key is changeable only on new models - so skip check if we are not
// new.
Query<?> query = new DefaultOrmQuery<>(beanDesc, this, expressionFactory);
@@ -2381,7 +2381,7 @@ public final class DefaultServer implements SpiServer, SpiEbeanServer {
Query<?> query = new DefaultOrmQuery<>(beanDesc, this, expressionFactory);
ExpressionList<?> exprList = query.where();
if (!entityBean._ebean_intercept().isNew()) {
if (!entityBean._ebean_getIntercept().isNew()) {
// if model is not new, exclude ourself.
exprList.ne(idProperty.getName(), idProperty.getVal(entityBean));
}