No effective change - code cleanup - unused params

This commit is contained in:
Robin Bygrave
2015-08-01 17:16:33 +12:00
parent dbd789f4be
commit a27433dc11
5 changed files with 9 additions and 19 deletions
@@ -4,7 +4,6 @@ import com.avaje.ebean.bean.EntityBean;
import com.avaje.ebean.config.EncryptKey;
import com.avaje.ebean.config.dbplatform.DbEncryptFunction;
import com.avaje.ebean.config.dbplatform.DbType;
import com.avaje.ebean.text.StringFormatter;
import com.avaje.ebean.text.StringParser;
import com.avaje.ebeaninternal.server.core.InternString;
import com.avaje.ebeaninternal.server.deploy.generatedproperty.GeneratedProperty;
@@ -534,11 +533,11 @@ public class BeanProperty implements ElPropertyValue {
return scalarType.read(ctx.getDataReader());
}
public Object readSet(DbReadContext ctx, EntityBean bean, Class<?> type) throws SQLException {
public Object readSet(DbReadContext ctx, EntityBean bean) throws SQLException {
try {
Object value = scalarType.read(ctx.getDataReader());
if (bean != null && ((type == null || owningType.isAssignableFrom(type)))) {
if (bean != null) {
setValue(bean, value);
}
return value;
@@ -782,10 +781,6 @@ public class BeanProperty implements ElPropertyValue {
return scalarType;
}
public StringFormatter getStringFormatter() {
return scalarType;
}
public StringParser getStringParser() {
return scalarType;
}
@@ -396,7 +396,7 @@ public class BeanPropertyAssocMany<T> extends BeanPropertyAssoc<T> {
}
@Override
public Object readSet(DbReadContext ctx, EntityBean bean, Class<?> type) throws SQLException {
public Object readSet(DbReadContext ctx, EntityBean bean) throws SQLException {
return null;
}
@@ -510,9 +510,8 @@ public class BeanPropertyAssocOne<T> extends BeanPropertyAssoc<T> {
}
@Override
public Object readSet(DbReadContext ctx, EntityBean bean, Class<?> type) throws SQLException {
boolean assignable = (type == null || owningType.isAssignableFrom(type));
return localHelp.readSet(ctx, bean, assignable);
public Object readSet(DbReadContext ctx, EntityBean bean) throws SQLException {
return localHelp.readSet(ctx, bean, true);
}
/**
@@ -614,7 +613,7 @@ public class BeanPropertyAssocOne<T> extends BeanPropertyAssoc<T> {
boolean notNull = false;
for (int i = 0; i < embeddedProps.length; i++) {
Object value = embeddedProps[i].readSet(ctx, embeddedBean, null);
Object value = embeddedProps[i].readSet(ctx, embeddedBean);
if (value != null) {
notNull = true;
}
@@ -123,14 +123,10 @@ public class BeanPropertyCompound extends BeanProperty {
}
@Override
public Object readSet(DbReadContext ctx, EntityBean bean, Class<?> type) throws SQLException {
boolean assignable = (type == null || owningType.isAssignableFrom(type));
public Object readSet(DbReadContext ctx, EntityBean bean) throws SQLException {
Object v = compoundType.read(ctx.getDataReader());
if (assignable) {
setValue(bean, v);
}
setValue(bean, v);
return v;
}
@@ -279,7 +279,7 @@ public final class IdBinderEmbedded implements IdBinder {
boolean notNull = true;
for (int i = 0; i < props.length; i++) {
Object value = props[i].readSet(ctx, embId, null);
Object value = props[i].readSet(ctx, embId);
if (value == null) {
notNull = false;
}