mirror of
https://github.com/ebean-orm/ebean.git
synced 2024-04-21 10:51:47 +00:00
#1747 - Refactor remove unused methods
This commit is contained in:
@@ -143,11 +143,6 @@ public class BeanDescriptor<T> implements BeanType<T>, STreeType {
|
||||
ORM, EMBEDDED, VIEW, SQL, DOC
|
||||
}
|
||||
|
||||
/**
|
||||
* The EbeanServer name. Same as the plugin name.
|
||||
*/
|
||||
private final String serverName;
|
||||
|
||||
/**
|
||||
* The nature/type of this bean.
|
||||
*/
|
||||
@@ -435,7 +430,6 @@ public class BeanDescriptor<T> implements BeanType<T>, STreeType {
|
||||
|
||||
this.owner = owner;
|
||||
this.multiValueSupported = owner.isMultiValueSupported();
|
||||
this.serverName = owner.getServerName();
|
||||
this.entityType = deploy.getEntityType();
|
||||
this.properties = deploy.getProperties();
|
||||
this.name = InternString.intern(deploy.getName());
|
||||
@@ -2132,7 +2126,8 @@ public class BeanDescriptor<T> implements BeanType<T>, STreeType {
|
||||
/**
|
||||
* Return the class type this BeanDescriptor describes.
|
||||
*/
|
||||
@Override @Nonnull
|
||||
@Override
|
||||
@Nonnull
|
||||
public Class<T> getBeanType() {
|
||||
return beanType;
|
||||
}
|
||||
@@ -2144,7 +2139,8 @@ public class BeanDescriptor<T> implements BeanType<T>, STreeType {
|
||||
* instead.
|
||||
* </p>
|
||||
*/
|
||||
@Override @Nonnull
|
||||
@Override
|
||||
@Nonnull
|
||||
public String getFullName() {
|
||||
return fullName;
|
||||
}
|
||||
@@ -2152,7 +2148,8 @@ public class BeanDescriptor<T> implements BeanType<T>, STreeType {
|
||||
/**
|
||||
* Return the short name of the entity bean.
|
||||
*/
|
||||
@Override @Nonnull
|
||||
@Override
|
||||
@Nonnull
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
@@ -3119,7 +3116,8 @@ public class BeanDescriptor<T> implements BeanType<T>, STreeType {
|
||||
return selectLastInsertedId != null;
|
||||
}
|
||||
|
||||
@Override @Nonnull
|
||||
@Override
|
||||
@Nonnull
|
||||
public Collection<? extends Property> allProperties() {
|
||||
return propertiesAll();
|
||||
}
|
||||
|
||||
@@ -28,7 +28,6 @@ import org.slf4j.LoggerFactory;
|
||||
import javax.persistence.PersistenceException;
|
||||
import java.io.IOException;
|
||||
import java.io.StringWriter;
|
||||
import java.sql.SQLException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
import java.util.LinkedHashMap;
|
||||
|
||||
@@ -32,11 +32,6 @@ public interface DbSqlContext {
|
||||
*/
|
||||
BeanProperty[] getEncryptedProps();
|
||||
|
||||
/**
|
||||
* Append a char directly to the SQL buffer.
|
||||
*/
|
||||
DbSqlContext append(char s);
|
||||
|
||||
/**
|
||||
* Append a string directly to the SQL buffer.
|
||||
*/
|
||||
|
||||
@@ -11,15 +11,6 @@ public class IndexDefinition {
|
||||
|
||||
private final boolean unique;
|
||||
|
||||
/**
|
||||
* A single column index.
|
||||
*/
|
||||
public IndexDefinition(String column, String name, boolean unique) {
|
||||
this.columns = new String[]{column};
|
||||
this.unique = unique;
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public IndexDefinition(String[] columns, String name, boolean unique) {
|
||||
this.columns = columns;
|
||||
this.unique = unique;
|
||||
|
||||
@@ -134,13 +134,6 @@ public final class TableJoin {
|
||||
return table;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the type of join. LEFT JOIN etc.
|
||||
*/
|
||||
public SqlJoinType getType() {
|
||||
return type;
|
||||
}
|
||||
|
||||
public void addJoin(SqlJoinType joinType, String prefix, DbSqlContext ctx, String predicate) {
|
||||
String[] names = SplitName.split(prefix);
|
||||
String a1 = ctx.getTableAlias(names[0]);
|
||||
|
||||
@@ -10,8 +10,6 @@ import io.ebeaninternal.server.type.DataBind;
|
||||
|
||||
import java.io.DataInput;
|
||||
import java.io.DataOutput;
|
||||
import java.io.IOException;
|
||||
import java.sql.SQLException;
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -155,7 +155,6 @@ public final class ImportedIdSimple implements ImportedId, Comparable<ImportedId
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public void dmlAppend(GenerateDmlRequest request) {
|
||||
request.appendColumn(localDbColumn);
|
||||
|
||||
@@ -37,7 +37,6 @@ import io.ebeaninternal.server.rawsql.SpiRawSql;
|
||||
|
||||
import javax.persistence.Entity;
|
||||
import javax.persistence.MappedSuperclass;
|
||||
import java.lang.reflect.Modifier;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
import java.util.Comparator;
|
||||
@@ -181,11 +180,6 @@ public class DeployBeanDescriptor<T> {
|
||||
*/
|
||||
private BeanFindController beanFinder;
|
||||
|
||||
/**
|
||||
* The table joins for this bean. Server side only.
|
||||
*/
|
||||
private final ArrayList<DeployTableJoin> tableJoinList = new ArrayList<>(2);
|
||||
|
||||
/**
|
||||
* Inheritance information. Server side only.
|
||||
*/
|
||||
@@ -245,7 +239,7 @@ public class DeployBeanDescriptor<T> {
|
||||
/**
|
||||
* Return true if there is a IdClass set.
|
||||
*/
|
||||
public boolean isIdClass() {
|
||||
boolean isIdClass() {
|
||||
return idClass != null;
|
||||
}
|
||||
|
||||
@@ -270,13 +264,6 @@ public class DeployBeanDescriptor<T> {
|
||||
return manager.getDeploy(cls);
|
||||
}
|
||||
|
||||
/**
|
||||
* Return true if this beanType is an abstract class.
|
||||
*/
|
||||
public boolean isAbstract() {
|
||||
return Modifier.isAbstract(beanType.getModifiers());
|
||||
}
|
||||
|
||||
public void setStorageEngine(String storageEngine) {
|
||||
this.storageEngine = storageEngine;
|
||||
}
|
||||
@@ -502,7 +489,7 @@ public class DeployBeanDescriptor<T> {
|
||||
return cacheOptions;
|
||||
}
|
||||
|
||||
public DeployBeanPropertyAssocOne<?> getIdClassProperty() {
|
||||
DeployBeanPropertyAssocOne<?> getIdClassProperty() {
|
||||
return idClassProperty;
|
||||
}
|
||||
|
||||
@@ -518,7 +505,7 @@ public class DeployBeanDescriptor<T> {
|
||||
this.orderColumn = orderColumn;
|
||||
}
|
||||
|
||||
public DeployBeanProperty getOrderColumn() {
|
||||
DeployBeanProperty getOrderColumn() {
|
||||
return orderColumn;
|
||||
}
|
||||
|
||||
@@ -949,17 +936,6 @@ public class DeployBeanDescriptor<T> {
|
||||
return getFullName();
|
||||
}
|
||||
|
||||
/**
|
||||
* Add a TableJoin to this type of bean. For Secondary table properties.
|
||||
*/
|
||||
public void addTableJoin(DeployTableJoin join) {
|
||||
tableJoinList.add(join);
|
||||
}
|
||||
|
||||
List<DeployTableJoin> getTableJoins() {
|
||||
return tableJoinList;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return a collection of all BeanProperty deployment information.
|
||||
*/
|
||||
@@ -1268,7 +1244,7 @@ public class DeployBeanDescriptor<T> {
|
||||
* Returns the jackson annotated class, if jackson is present.
|
||||
*/
|
||||
@SuppressWarnings("unchecked")
|
||||
public Object /*AnnotatedClass*/ getJacksonAnnotatedClass() {
|
||||
Object /*AnnotatedClass*/ getJacksonAnnotatedClass() {
|
||||
if (jacksonAnnotatedClass == null) {
|
||||
jacksonAnnotatedClass = new DeployBeanObtainJackson(serverConfig, beanType).obtain();
|
||||
}
|
||||
|
||||
@@ -66,8 +66,6 @@ public class DeployBeanPropertyLists {
|
||||
|
||||
private final List<BeanProperty> nonTransients = new ArrayList<>();
|
||||
|
||||
private final TableJoin[] tableJoins;
|
||||
|
||||
private final BeanPropertyAssocOne<?> unidirectional;
|
||||
private final BeanProperty orderColumn;
|
||||
|
||||
@@ -138,12 +136,6 @@ public class DeployBeanPropertyLists {
|
||||
// (after the real properties have been organised into their lists)
|
||||
propertyMap.put(discProperty.getName(), discProperty);
|
||||
}
|
||||
|
||||
List<DeployTableJoin> deployTableJoins = deploy.getTableJoins();
|
||||
tableJoins = new TableJoin[deployTableJoins.size()];
|
||||
for (int i = 0; i < deployTableJoins.size(); i++) {
|
||||
tableJoins[i] = new TableJoin(deployTableJoins.get(i));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -275,10 +267,6 @@ public class DeployBeanPropertyLists {
|
||||
return propertyMap;
|
||||
}
|
||||
|
||||
public TableJoin[] getTableJoin() {
|
||||
return tableJoins;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the base scalar properties (excludes Id and secondary table
|
||||
* properties).
|
||||
|
||||
@@ -231,12 +231,6 @@ class DefaultDbSqlContext implements DbSqlContext {
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public DefaultDbSqlContext append(char s) {
|
||||
sb.append(s);
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void appendFormulaJoin(String sqlFormulaJoin, SqlJoinType joinType) {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user