diff --git a/src/main/java/com/avaje/ebeaninternal/api/LoadBeanBuffer.java b/src/main/java/com/avaje/ebeaninternal/api/LoadBeanBuffer.java index 862c6f61d..82e26aa9b 100644 --- a/src/main/java/com/avaje/ebeaninternal/api/LoadBeanBuffer.java +++ b/src/main/java/com/avaje/ebeaninternal/api/LoadBeanBuffer.java @@ -11,16 +11,16 @@ import com.avaje.ebeaninternal.server.deploy.BeanDescriptor; */ public interface LoadBeanBuffer { - public int getBatchSize(); + int getBatchSize(); - public List getBatch(); + List getBatch(); - public BeanDescriptor getBeanDescriptor(); + BeanDescriptor getBeanDescriptor(); - public PersistenceContext getPersistenceContext(); + PersistenceContext getPersistenceContext(); - public String getFullPath(); + String getFullPath(); - public void configureQuery(SpiQuery query, String lazyLoadProperty); + void configureQuery(SpiQuery query, String lazyLoadProperty); } \ No newline at end of file diff --git a/src/main/java/com/avaje/ebeaninternal/api/LoadContext.java b/src/main/java/com/avaje/ebeaninternal/api/LoadContext.java index ac999599d..14670a014 100644 --- a/src/main/java/com/avaje/ebeaninternal/api/LoadContext.java +++ b/src/main/java/com/avaje/ebeaninternal/api/LoadContext.java @@ -14,13 +14,13 @@ public interface LoadContext { /** * Return the minimum batch size when using QueryIterator with query joins. */ - public int getSecondaryQueriesMinBatchSize(OrmQueryRequest parentRequest, int defaultQueryBatch); + int getSecondaryQueriesMinBatchSize(OrmQueryRequest parentRequest, int defaultQueryBatch); /** * Execute any secondary (+query) queries if there are any defined. * @param parentRequest the originating query request */ - public void executeSecondaryQueries(OrmQueryRequest parentRequest); + void executeSecondaryQueries(OrmQueryRequest parentRequest); /** * Register any secondary queries (+query or +lazy) with their @@ -30,17 +30,17 @@ public interface LoadContext { * defined query for +query and +lazy execution. *

*/ - public void registerSecondaryQueries(SpiQuery query); + void registerSecondaryQueries(SpiQuery query); /** * Return the node for a given path which is used by autofetch profiling. */ - public ObjectGraphNode getObjectGraphNode(String path); + ObjectGraphNode getObjectGraphNode(String path); /** * Return the persistence context used by this query and future lazy loading. */ - public PersistenceContext getPersistenceContext(); + PersistenceContext getPersistenceContext(); /** * Set the persistence context used by this query and future lazy loading. @@ -48,16 +48,16 @@ public interface LoadContext { * Used by query iterator when processing large result sets. *

*/ - public void resetPersistenceContext(PersistenceContext persistenceContext); + void resetPersistenceContext(PersistenceContext persistenceContext); /** * Register a Bean for lazy loading. */ - public void register(String path, EntityBeanIntercept ebi); + void register(String path, EntityBeanIntercept ebi); /** * Register a collection for lazy loading. */ - public void register(String path, BeanCollection bc); + void register(String path, BeanCollection bc); } diff --git a/src/main/java/com/avaje/ebeaninternal/api/LoadManyBuffer.java b/src/main/java/com/avaje/ebeaninternal/api/LoadManyBuffer.java index 761f1df58..cd8701768 100644 --- a/src/main/java/com/avaje/ebeaninternal/api/LoadManyBuffer.java +++ b/src/main/java/com/avaje/ebeaninternal/api/LoadManyBuffer.java @@ -13,20 +13,20 @@ import com.avaje.ebeaninternal.server.deploy.BeanPropertyAssocMany; */ public interface LoadManyBuffer { - public int getBatchSize(); + int getBatchSize(); - public List> getBatch(); + List> getBatch(); - public BeanPropertyAssocMany getBeanProperty(); + BeanPropertyAssocMany getBeanProperty(); - public ObjectGraphNode getObjectGraphNode(); + ObjectGraphNode getObjectGraphNode(); - public BeanDescriptor getBeanDescriptor(); + BeanDescriptor getBeanDescriptor(); - public PersistenceContext getPersistenceContext(); + PersistenceContext getPersistenceContext(); - public String getFullPath(); + String getFullPath(); - public void configureQuery(SpiQuery query); + void configureQuery(SpiQuery query); } \ No newline at end of file diff --git a/src/main/java/com/avaje/ebeaninternal/api/LoadSecondaryQuery.java b/src/main/java/com/avaje/ebeaninternal/api/LoadSecondaryQuery.java index 147ede69a..f109d20a9 100644 --- a/src/main/java/com/avaje/ebeaninternal/api/LoadSecondaryQuery.java +++ b/src/main/java/com/avaje/ebeaninternal/api/LoadSecondaryQuery.java @@ -14,5 +14,5 @@ public interface LoadSecondaryQuery { /** * Execute the secondary query with a given batch size. */ - public void loadSecondaryQuery(OrmQueryRequest parentRequest); + void loadSecondaryQuery(OrmQueryRequest parentRequest); } diff --git a/src/main/java/com/avaje/ebeaninternal/api/SpiBackgroundExecutor.java b/src/main/java/com/avaje/ebeaninternal/api/SpiBackgroundExecutor.java index 6a1d7e069..c4bf5f744 100644 --- a/src/main/java/com/avaje/ebeaninternal/api/SpiBackgroundExecutor.java +++ b/src/main/java/com/avaje/ebeaninternal/api/SpiBackgroundExecutor.java @@ -10,5 +10,5 @@ public interface SpiBackgroundExecutor extends BackgroundExecutor { /** * Shutdown any associated thread pools. */ - public void shutdown(); + void shutdown(); } diff --git a/src/main/java/com/avaje/ebeaninternal/api/SpiCallableSql.java b/src/main/java/com/avaje/ebeaninternal/api/SpiCallableSql.java index 933c0e173..152492c26 100644 --- a/src/main/java/com/avaje/ebeaninternal/api/SpiCallableSql.java +++ b/src/main/java/com/avaje/ebeaninternal/api/SpiCallableSql.java @@ -4,7 +4,7 @@ import com.avaje.ebean.CallableSql; public interface SpiCallableSql extends CallableSql { - public BindParams getBindParams(); + BindParams getBindParams(); - public TransactionEventTable getTransactionEventTable(); + TransactionEventTable getTransactionEventTable(); } diff --git a/src/main/java/com/avaje/ebeaninternal/api/SpiEbeanPlugin.java b/src/main/java/com/avaje/ebeaninternal/api/SpiEbeanPlugin.java index 4496b69d5..e4e2280ae 100644 --- a/src/main/java/com/avaje/ebeaninternal/api/SpiEbeanPlugin.java +++ b/src/main/java/com/avaje/ebeaninternal/api/SpiEbeanPlugin.java @@ -9,6 +9,7 @@ import com.avaje.ebean.config.dbplatform.DatabasePlatform; * author: Richard Vowles - http://gplus.to/RichardVowles */ public interface SpiEbeanPlugin { + /** * initializes the plugin. * @@ -16,7 +17,10 @@ public interface SpiEbeanPlugin { * @param dbPlatform - the database we are using - this is available from the server, but it is provided for convenience * @param serverConfig - the configured server information. It allows access to pre-collected information (but not the collector PropertySource, yet) */ - public void setup(SpiEbeanServer server, DatabasePlatform dbPlatform, ServerConfig serverConfig); + void setup(SpiEbeanServer server, DatabasePlatform dbPlatform, ServerConfig serverConfig); - public void execute(boolean online); + /** + * Execute the plugin (generate DDL for example). + */ + void execute(boolean online); } diff --git a/src/main/java/com/avaje/ebeaninternal/api/SpiEbeanServer.java b/src/main/java/com/avaje/ebeaninternal/api/SpiEbeanServer.java index 1cdfd6cfe..39d51e7cb 100644 --- a/src/main/java/com/avaje/ebeaninternal/api/SpiEbeanServer.java +++ b/src/main/java/com/avaje/ebeaninternal/api/SpiEbeanServer.java @@ -26,22 +26,22 @@ public interface SpiEbeanServer extends EbeanServer, BeanLoader, BeanCollectionL /** * For internal use, shutdown of the server invoked by JVM Shutdown. */ - public void shutdownManaged(); + void shutdownManaged(); /** * Return true if query origins should be collected. */ - public boolean isCollectQueryOrigins(); + boolean isCollectQueryOrigins(); /** * Return the server configuration. */ - public ServerConfig getServerConfig(); + ServerConfig getServerConfig(); /** * Return the DatabasePlatform for this server. */ - public DatabasePlatform getDatabasePlatform(); + DatabasePlatform getDatabasePlatform(); /** * Return a JDBC driver specific handler for batching. @@ -49,7 +49,7 @@ public interface SpiEbeanServer extends EbeanServer, BeanLoader, BeanCollectionL * Required for Oracle specific batch handling. *

*/ - public PstmtBatch getPstmtBatch(); + PstmtBatch getPstmtBatch(); /** * Create an object to represent the current CallStack. @@ -58,47 +58,47 @@ public interface SpiEbeanServer extends EbeanServer, BeanLoader, BeanCollectionL * graph costing. *

*/ - public CallStack createCallStack(); + CallStack createCallStack(); /** * Return the PersistenceContextScope to use defined at query or server level. */ - public PersistenceContextScope getPersistenceContextScope(SpiQuery query); + PersistenceContextScope getPersistenceContextScope(SpiQuery query); /** * Return the DDL generator. */ - public DdlGenerator getDdlGenerator(); + DdlGenerator getDdlGenerator(); /** * Return the AutoFetchListener. */ - public AutoFetchManager getAutoFetchManager(); + AutoFetchManager getAutoFetchManager(); /** * Clear the query execution statistics. */ - public void clearQueryStatistics(); + void clearQueryStatistics(); /** * Return all the descriptors. */ - public List> getBeanDescriptors(); + List> getBeanDescriptors(); /** * Return the BeanDescriptor for a given type of bean. */ - public BeanDescriptor getBeanDescriptor(Class type); + BeanDescriptor getBeanDescriptor(Class type); /** * Return BeanDescriptor using it's unique id. */ - public BeanDescriptor getBeanDescriptorById(String descriptorId); + BeanDescriptor getBeanDescriptorById(String descriptorId); /** * Return BeanDescriptors mapped to this table. */ - public List> getBeanDescriptors(String tableName); + List> getBeanDescriptors(String tableName); /** * Process committed changes from another framework. @@ -108,7 +108,7 @@ public interface SpiEbeanServer extends EbeanServer, BeanLoader, BeanCollectionL * this to maintain its cache and text indexes appropriately. *

*/ - public void externalModification(TransactionEventTable event); + void externalModification(TransactionEventTable event); /** * Create a ServerTransaction. @@ -116,44 +116,44 @@ public interface SpiEbeanServer extends EbeanServer, BeanLoader, BeanCollectionL * To specify to use the default transaction isolation use a value of -1. *

*/ - public SpiTransaction createServerTransaction(boolean isExplicit, int isolationLevel); + SpiTransaction createServerTransaction(boolean isExplicit, int isolationLevel); /** * Return the current transaction or null if there is no current transaction. */ - public SpiTransaction getCurrentServerTransaction(); + SpiTransaction getCurrentServerTransaction(); /** * Create a ScopeTrans for a method for the given scope definition. */ - public ScopeTrans createScopeTrans(TxScope txScope); + ScopeTrans createScopeTrans(TxScope txScope); /** * Create a ServerTransaction for query purposes. */ - public SpiTransaction createQueryTransaction(); + SpiTransaction createQueryTransaction(); /** * An event from another server in the cluster used to notify local * BeanListeners of remote inserts updates and deletes. */ - public void remoteTransactionEvent(RemoteTransactionEvent event); + void remoteTransactionEvent(RemoteTransactionEvent event); /** * Create a query request object. */ - public SpiOrmQueryRequest createQueryRequest(BeanDescriptor desc, SpiQuery q, + SpiOrmQueryRequest createQueryRequest(BeanDescriptor desc, SpiQuery q, Transaction t); /** * Compile a query. */ - public CQuery compileQuery(Query query, Transaction t); + CQuery compileQuery(Query query, Transaction t); /** * Return the queryEngine for this server. */ - public CQueryEngine getQueryEngine(); + CQueryEngine getQueryEngine(); /** * Execute the findId's query but without copying the query. @@ -162,37 +162,37 @@ public interface SpiEbeanServer extends EbeanServer, BeanLoader, BeanCollectionL * the query has finished (if executing in a background thread). *

*/ - public List findIdsWithCopy(Query query, Transaction t); + List findIdsWithCopy(Query query, Transaction t); /** * Execute the findRowCount query but without copying the query. */ - public int findRowCountWithCopy(Query query, Transaction t); + int findRowCountWithCopy(Query query, Transaction t); /** * Load a batch of Associated One Beans. */ - public void loadBean(LoadBeanRequest loadRequest); + void loadBean(LoadBeanRequest loadRequest); /** * Lazy load a batch of Many's. */ - public void loadMany(LoadManyRequest loadRequest); + void loadMany(LoadManyRequest loadRequest); /** * Return the default batch size for lazy loading. */ - public int getLazyLoadBatchSize(); + int getLazyLoadBatchSize(); /** * Return true if the type is known as an Entity or Xml type or a List Set or * Map of known bean types. */ - public boolean isSupportedType(java.lang.reflect.Type genericType); + boolean isSupportedType(java.lang.reflect.Type genericType); /** * Collect query statistics by ObjectGraphNode. Used for Lazy loading reporting. */ - public void collectQueryStats(ObjectGraphNode objectGraphNode, long loadedBeanCount, long timeMicros); + void collectQueryStats(ObjectGraphNode objectGraphNode, long loadedBeanCount, long timeMicros); } diff --git a/src/main/java/com/avaje/ebeaninternal/api/SpiExpression.java b/src/main/java/com/avaje/ebeaninternal/api/SpiExpression.java index d7332f7d8..ca64b37b9 100644 --- a/src/main/java/com/avaje/ebeaninternal/api/SpiExpression.java +++ b/src/main/java/com/avaje/ebeaninternal/api/SpiExpression.java @@ -16,7 +16,7 @@ public interface SpiExpression extends Expression { * Predicates on Many properties require an extra independent join clause. *

*/ - public void containsMany(BeanDescriptor desc, ManyWhereJoins whereManyJoins); + void containsMany(BeanDescriptor desc, ManyWhereJoins whereManyJoins); /** * Calculate a hash value used to identify a query for AutoFetch tuning. @@ -25,7 +25,7 @@ public interface SpiExpression extends Expression { * from an AutoFetch perspective and get different tuning. *

*/ - public void queryAutoFetchHash(HashQueryPlanBuilder builder); + void queryAutoFetchHash(HashQueryPlanBuilder builder); /** * Calculate a hash value for the expression. @@ -36,12 +36,12 @@ public interface SpiExpression extends Expression { * case the query execution plan can be reused. *

*/ - public void queryPlanHash(BeanQueryRequest request, HashQueryPlanBuilder builder); + void queryPlanHash(BeanQueryRequest request, HashQueryPlanBuilder builder); /** * Return the hash value for the values that will be bound. */ - public int queryBindHash(); + int queryBindHash(); /** * Add some sql to the query. @@ -56,7 +56,7 @@ public interface SpiExpression extends Expression { * @param request * the associated request. */ - public void addSql(SpiExpressionRequest request); + void addSql(SpiExpressionRequest request); /** * Add the parameter values to be set against query. For each ? place holder @@ -65,5 +65,5 @@ public interface SpiExpression extends Expression { * @param request * the associated request. */ - public void addBindValues(SpiExpressionRequest request); + void addBindValues(SpiExpressionRequest request); } diff --git a/src/main/java/com/avaje/ebeaninternal/api/SpiExpressionFactory.java b/src/main/java/com/avaje/ebeaninternal/api/SpiExpressionFactory.java index 3592598ba..d56cb0225 100644 --- a/src/main/java/com/avaje/ebeaninternal/api/SpiExpressionFactory.java +++ b/src/main/java/com/avaje/ebeaninternal/api/SpiExpressionFactory.java @@ -7,6 +7,6 @@ public interface SpiExpressionFactory extends ExpressionFactory { /** * Create another expression factory with a given sub path. */ - public ExpressionFactory createExpressionFactory(); + ExpressionFactory createExpressionFactory(); } diff --git a/src/main/java/com/avaje/ebeaninternal/api/SpiExpressionList.java b/src/main/java/com/avaje/ebeaninternal/api/SpiExpressionList.java index d5467593d..87121f0fa 100644 --- a/src/main/java/com/avaje/ebeaninternal/api/SpiExpressionList.java +++ b/src/main/java/com/avaje/ebeaninternal/api/SpiExpressionList.java @@ -16,17 +16,17 @@ public interface SpiExpressionList extends ExpressionList { /** * Return the underlying list of expressions. */ - public List getUnderlyingList(); + List getUnderlyingList(); /** * Return a copy of the ExpressionList with the path trimmed for filterMany() expressions. */ - public SpiExpressionList trimPath(int prefixTrim); + SpiExpressionList trimPath(int prefixTrim); /** * Restore the ExpressionFactory after deserialisation. */ - public void setExpressionFactory(ExpressionFactory expr); + void setExpressionFactory(ExpressionFactory expr); /** * Process "Many" properties populating ManyWhereJoins. @@ -34,12 +34,12 @@ public interface SpiExpressionList extends ExpressionList { * Predicates on Many properties require an extra independent join clause. *

*/ - public void containsMany(BeanDescriptor desc, ManyWhereJoins manyWhereJoins); + void containsMany(BeanDescriptor desc, ManyWhereJoins manyWhereJoins); /** * Return true if this list is empty. */ - public boolean isEmpty(); + boolean isEmpty(); /** * Concatenate the expression sql into a String. @@ -48,7 +48,7 @@ public interface SpiExpressionList extends ExpressionList { * with bind parameters. *

*/ - public String buildSql(SpiExpressionRequest request); + String buildSql(SpiExpressionRequest request); /** * Combine the expression bind values into a list. @@ -59,12 +59,12 @@ public interface SpiExpressionList extends ExpressionList { * * @return the list of all the bind values in order. */ - public ArrayList buildBindValues(SpiExpressionRequest request); + ArrayList buildBindValues(SpiExpressionRequest request); /** * Calculate a hash based on the expressions but excluding the actual bind * values. */ - public void queryPlanHash(BeanQueryRequest request, HashQueryPlanBuilder builder); + void queryPlanHash(BeanQueryRequest request, HashQueryPlanBuilder builder); } diff --git a/src/main/java/com/avaje/ebeaninternal/api/SpiExpressionRequest.java b/src/main/java/com/avaje/ebeaninternal/api/SpiExpressionRequest.java index 0e11a5f82..883d6d5ba 100644 --- a/src/main/java/com/avaje/ebeaninternal/api/SpiExpressionRequest.java +++ b/src/main/java/com/avaje/ebeaninternal/api/SpiExpressionRequest.java @@ -13,45 +13,45 @@ public interface SpiExpressionRequest { /** * Parse the logical property name to the deployment name. */ - public String parseDeploy(String logicalProp); + String parseDeploy(String logicalProp); /** * Return the bean descriptor for the root type. */ - public BeanDescriptor getBeanDescriptor(); + BeanDescriptor getBeanDescriptor(); /** * Return the associated QueryRequest. */ - public SpiOrmQueryRequest getQueryRequest(); + SpiOrmQueryRequest getQueryRequest(); /** * Append to the expression sql. */ - public SpiExpressionRequest append(String sql); + SpiExpressionRequest append(String sql); /** * Add a bind value to this request. */ - public void addBindValue(Object bindValue); + void addBindValue(Object bindValue); /** * Return the accumulated expression sql for all expressions in this request. */ - public String getSql(); + String getSql(); /** * Return the ordered list of bind values for all expressions in this request. */ - public ArrayList getBindValues(); + ArrayList getBindValues(); /** * Increments the parameter index and returns that value. */ - public int nextParameter(); + int nextParameter(); /** * Append a DB Like clause. */ - public void appendLike(); + void appendLike(); } diff --git a/src/main/java/com/avaje/ebeaninternal/api/SpiSqlQuery.java b/src/main/java/com/avaje/ebeaninternal/api/SpiSqlQuery.java index 2496d5b73..12725e0be 100644 --- a/src/main/java/com/avaje/ebeaninternal/api/SpiSqlQuery.java +++ b/src/main/java/com/avaje/ebeaninternal/api/SpiSqlQuery.java @@ -10,68 +10,68 @@ import com.avaje.ebean.SqlQueryListener; */ public interface SpiSqlQuery extends SqlQuery { - /** - * Return the named or positioned parameters. - */ - public BindParams getBindParams(); + /** + * Return the named or positioned parameters. + */ + BindParams getBindParams(); - /** - * return the query. - */ - public String getQuery(); + /** + * return the query. + */ + String getQuery(); - /** - * Return the queryListener. - */ - public SqlQueryListener getListener(); - - /** - * Return the first row to fetch. - */ - public int getFirstRow(); - - /** - * Return the maximum number of rows to fetch. - */ - public int getMaxRows(); - - /** - * Return the number of rows after which background fetching occurs. - */ - public int getBackgroundFetchAfter(); - - /** - * Return the key property for maps. - */ - public String getMapKey(); - - /** - * Return the query timeout. - */ - public int getTimeout(); + /** + * Return the queryListener. + */ + SqlQueryListener getListener(); - /** - * Return the hint for Statement.setFetchSize(). - */ - public int getBufferFetchSizeHint(); + /** + * Return the first row to fetch. + */ + int getFirstRow(); - /** - * Return true if this is a future fetch type query. - */ - public boolean isFutureFetch(); + /** + * Return the maximum number of rows to fetch. + */ + int getMaxRows(); - /** - * Set to true if this is a future fetch type query. - */ - public void setFutureFetch(boolean futureFetch); + /** + * Return the number of rows after which background fetching occurs. + */ + int getBackgroundFetchAfter(); - /** - * Set the PreparedStatement for the purposes of supporting cancel. - */ - public void setPreparedStatement(PreparedStatement pstmt); - - /** - * Return true if the query has been cancelled. - */ - public boolean isCancelled(); + /** + * Return the key property for maps. + */ + String getMapKey(); + + /** + * Return the query timeout. + */ + int getTimeout(); + + /** + * Return the hint for Statement.setFetchSize(). + */ + int getBufferFetchSizeHint(); + + /** + * Return true if this is a future fetch type query. + */ + boolean isFutureFetch(); + + /** + * Set to true if this is a future fetch type query. + */ + void setFutureFetch(boolean futureFetch); + + /** + * Set the PreparedStatement for the purposes of supporting cancel. + */ + void setPreparedStatement(PreparedStatement pstmt); + + /** + * Return true if the query has been cancelled. + */ + boolean isCancelled(); } diff --git a/src/main/java/com/avaje/ebeaninternal/api/SpiSqlUpdate.java b/src/main/java/com/avaje/ebeaninternal/api/SpiSqlUpdate.java index fe8d55006..2060a9c9a 100644 --- a/src/main/java/com/avaje/ebeaninternal/api/SpiSqlUpdate.java +++ b/src/main/java/com/avaje/ebeaninternal/api/SpiSqlUpdate.java @@ -4,7 +4,7 @@ import com.avaje.ebean.SqlUpdate; public interface SpiSqlUpdate extends SqlUpdate { - public BindParams getBindParams(); + BindParams getBindParams(); - public void setGeneratedSql(String sql); + void setGeneratedSql(String sql); } diff --git a/src/main/java/com/avaje/ebeaninternal/api/SpiTransaction.java b/src/main/java/com/avaje/ebeaninternal/api/SpiTransaction.java index 8b095b70a..f0d41f192 100644 --- a/src/main/java/com/avaje/ebeaninternal/api/SpiTransaction.java +++ b/src/main/java/com/avaje/ebeaninternal/api/SpiTransaction.java @@ -20,45 +20,45 @@ public interface SpiTransaction extends Transaction { /** * End the transaction when had query only use. */ - public void endQueryOnly(); + void endQueryOnly(); /** * Return the string prefix with the transactin id and label used in logging. */ - public String getLogPrefix(); + String getLogPrefix(); /** * Return true if generated SQL and Bind values should be logged to the * transaction log. */ - public boolean isLogSql(); + boolean isLogSql(); /** * Return true if summary level events should be logged to the transaction * log. */ - public boolean isLogSummary(); + boolean isLogSummary(); /** * Log a message to the SQL logger. */ - public void logSql(String msg); + void logSql(String msg); /** * Log a message to the SUMMARY logger. */ - public void logSummary(String msg); + void logSummary(String msg); /** * Register a "Derived Relationship" (that requires an additional update). */ - public void registerDerivedRelationship(DerivedRelationshipData assocBean); + void registerDerivedRelationship(DerivedRelationshipData assocBean); /** * Return the list of "Derived Relationships" that must be maintained after * insert. */ - public List getDerivedRelationship(Object bean); + List getDerivedRelationship(Object bean); /** * Add a deleting bean to the registered list. @@ -66,22 +66,22 @@ public interface SpiTransaction extends Transaction { * This is to handle bi-directional relationships where both sides Cascade. *

*/ - public void registerDeleteBean(Integer hash); + void registerDeleteBean(Integer hash); /** * Unregister the hash of the bean. */ - public void unregisterDeleteBean(Integer hash); + void unregisterDeleteBean(Integer hash); /** * Return true if this is a bean that has already been saved/deleted. */ - public boolean isRegisteredDeleteBean(Integer hash); + boolean isRegisteredDeleteBean(Integer hash); /** * Unregister the persisted bean. */ - public void unregisterBean(Object bean); + void unregisterBean(Object bean); /** * Return true if this is a bean that has already been persisted in the @@ -91,13 +91,13 @@ public interface SpiTransaction extends Transaction { * This will register the bean if it is not already. *

*/ - public boolean isRegisteredBean(Object bean); + boolean isRegisteredBean(Object bean); /** * Returns a String used to identify the transaction. This id is used for * Transaction logging. */ - public String getId(); + String getId(); /** * Return the batchSize specifically set for this transaction or 0. @@ -105,7 +105,7 @@ public interface SpiTransaction extends Transaction { * Returning 0 implies to use the system wide default batch size. *

*/ - public int getBatchSize(); + int getBatchSize(); /** * Modify and return the current 'depth' of the transaction. @@ -119,18 +119,18 @@ public interface SpiTransaction extends Transaction { * executed first during save. *

*/ - public int depth(int diff); + int depth(int diff); /** * Return the current depth. */ - public int depth(); + int depth(); /** * Return true if this transaction was created explicitly via * Ebean.beginTransaction(). */ - public boolean isExplicit(); + boolean isExplicit(); /** * Get the object that holds the event details. @@ -140,29 +140,29 @@ public interface SpiTransaction extends Transaction { * around the cluster (if you have a cluster). *

*/ - public TransactionEvent getEvent(); + TransactionEvent getEvent(); /** * Whether persistCascade is on for save and delete. */ - public boolean isPersistCascade(); + boolean isPersistCascade(); /** * Return true if this request should be batched. Conversely returns false * if this request should be executed immediately. */ - public boolean isBatchThisRequest(PersistRequest.Type type); + boolean isBatchThisRequest(PersistRequest.Type type); /** * Return the queue used to batch up persist requests. */ - public BatchControl getBatchControl(); + BatchControl getBatchControl(); /** * Set the queue used to batch up persist requests. There should only be one * PersistQueue set per transaction. */ - public void setBatchControl(BatchControl control); + void setBatchControl(BatchControl control); /** * Return the persistence context associated with this transaction. @@ -172,7 +172,7 @@ public interface SpiTransaction extends Transaction { * behaviour. *

*/ - public PersistenceContext getPersistenceContext(); + PersistenceContext getPersistenceContext(); /** * Set the persistence context to this transaction. @@ -185,47 +185,46 @@ public interface SpiTransaction extends Transaction { * PersistenceContext with multiple transactions. *

*/ - public void setPersistenceContext(PersistenceContext context); + void setPersistenceContext(PersistenceContext context); /** * Return the underlying Connection for internal use. *

- * If the connection is made public from Transaction and the user code calls + * If the connection is made from Transaction and the user code calls * that method we can no longer trust the query only status of a * Transaction. *

*/ - public Connection getInternalConnection(); + Connection getInternalConnection(); /** * Return true if the manyToMany intersection should be persisted for this particular relationship direction. */ - public boolean isSaveAssocManyIntersection(String intersectionTable, String beanName); + boolean isSaveAssocManyIntersection(String intersectionTable, String beanName); /** * Return true if batch mode got escalated for this request (and associated cascades). */ - public boolean checkBatchEscalationOnCascade(PersistRequestBean request); + boolean checkBatchEscalationOnCascade(PersistRequestBean request); /** * If batch mode was turned on for the request then flush the batch. */ - public void flushBatchOnCascade(); + void flushBatchOnCascade(); /** * Mark the transaction explicitly as not being query only. */ - public void markNotQueryOnly(); + void markNotQueryOnly(); /** * Potentially escalate batch mode on saving or deleting a collection. */ - public void checkBatchEscalationOnCollection(); + void checkBatchEscalationOnCollection(); /** * Flush batch if we escalated batch mode on saving or deleting a collection. */ - public void flushBatchOnCollection(); - + void flushBatchOnCollection(); } diff --git a/src/main/java/com/avaje/ebeaninternal/api/SpiTransactionScopeManager.java b/src/main/java/com/avaje/ebeaninternal/api/SpiTransactionScopeManager.java index 64198d67f..881b32c49 100644 --- a/src/main/java/com/avaje/ebeaninternal/api/SpiTransactionScopeManager.java +++ b/src/main/java/com/avaje/ebeaninternal/api/SpiTransactionScopeManager.java @@ -2,5 +2,5 @@ package com.avaje.ebeaninternal.api; public interface SpiTransactionScopeManager { - public void replace(SpiTransaction t); + void replace(SpiTransaction t); } diff --git a/src/main/java/com/avaje/ebeaninternal/api/SpiUpdate.java b/src/main/java/com/avaje/ebeaninternal/api/SpiUpdate.java index 57b3c3dbe..04d7be2b9 100644 --- a/src/main/java/com/avaje/ebeaninternal/api/SpiUpdate.java +++ b/src/main/java/com/avaje/ebeaninternal/api/SpiUpdate.java @@ -11,66 +11,66 @@ public interface SpiUpdate extends Update { * The type of the update request. */ enum OrmUpdateType { - INSERT{ + INSERT { public String toString() { return "Insert"; } }, - UPDATE{ + UPDATE { public String toString() { return "Update"; } - }, - DELETE{ + }, + DELETE { public String toString() { return "Delete"; } }, - UNKNOWN{ + UNKNOWN { public String toString() { return "Unknown"; } - - }; + + } } /** * Return the type of bean being updated. */ - public Class getBeanType(); + Class getBeanType(); /** * Return the type of this - insert, update or delete. */ - public OrmUpdateType getOrmUpdateType(); + OrmUpdateType getOrmUpdateType(); /** * Return the name of the table being modified. */ - public String getBaseTable(); + String getBaseTable(); /** * Return the update statement. This could be either sql or an orm update with bean types and property names. */ - public String getUpdateStatement(); + String getUpdateStatement(); /** * Return the timeout in seconds. */ - public int getTimeout(); + int getTimeout(); /** * Return true if the cache should be notified to invalidate objects. */ - public boolean isNotifyCache(); + boolean isNotifyCache(); /** * Return the bind parameters. */ - public BindParams getBindParams(); + BindParams getBindParams(); /** * Set the generated sql used. */ - public void setGeneratedSql(String sql); + void setGeneratedSql(String sql); } diff --git a/src/main/java/com/avaje/ebeaninternal/api/SpiUpdatePlan.java b/src/main/java/com/avaje/ebeaninternal/api/SpiUpdatePlan.java index f89b87f3b..7fda11b34 100644 --- a/src/main/java/com/avaje/ebeaninternal/api/SpiUpdatePlan.java +++ b/src/main/java/com/avaje/ebeaninternal/api/SpiUpdatePlan.java @@ -16,8 +16,6 @@ import com.avaje.ebeaninternal.server.persist.dmlbind.Bindable; *

* The plans are cached by the BeanDescriptors. * - * - * @author rbygrave */ public interface SpiUpdatePlan { @@ -28,48 +26,42 @@ public interface SpiUpdatePlan { * deployment. *

*/ - public boolean isEmptySetClause(); + boolean isEmptySetClause(); /** * Bind given the request and bean. The bean could be the oldValues bean * when binding a update or delete where clause with ALL concurrency mode. */ - public void bindSet(DmlHandler bind, EntityBean bean) throws SQLException; + void bindSet(DmlHandler bind, EntityBean bean) throws SQLException; /** * Return the time this plan was created. */ - public long getTimeCreated(); + long getTimeCreated(); /** * Return the time this plan was last used. */ - public Long getTimeLastUsed(); + Long getTimeLastUsed(); /** * Return the hash key for this plan. */ - public Integer getKey(); + Integer getKey(); /** * Return the concurrency mode for this plan. */ - public ConcurrencyMode getMode(); + ConcurrencyMode getMode(); /** * Return the update SQL statement. */ - public String getSql(); + String getSql(); /** * Return the set of bindable update properties. */ - public Bindable getSet(); - -// /** -// * Return the properties that where changed and should be included in the -// * update statement. -// */ -// public Set getProperties(); + Bindable getSet(); } \ No newline at end of file diff --git a/src/main/java/com/avaje/ebeaninternal/server/deploy/ChainedBeanPersistController.java b/src/main/java/com/avaje/ebeaninternal/server/deploy/ChainedBeanPersistController.java index 8f87fe230..c00f8e4b1 100644 --- a/src/main/java/com/avaje/ebeaninternal/server/deploy/ChainedBeanPersistController.java +++ b/src/main/java/com/avaje/ebeaninternal/server/deploy/ChainedBeanPersistController.java @@ -40,7 +40,6 @@ public class ChainedBeanPersistController implements BeanPersistController { /** * Construct given the list of BeanPersistController's. - * @param list */ public ChainedBeanPersistController(List list) { this.list = list;