Module is.codion.framework.db.core
Package is.codion.framework.db
Interface EntityConnection.BatchCopy.Builder
- Enclosing interface:
- EntityConnection.BatchCopy
public static interface EntityConnection.BatchCopy.Builder
A builder for a
EntityConnection.BatchCopy
operation.-
Method Summary
Modifier and TypeMethodDescriptionbatchSize
(int batchSize) build()
conditions
(Condition... conditions) entityTypes
(EntityType... entityTypes) void
execute()
Builds and executes this copy operationincludePrimaryKeys
(boolean includePrimaryKeys)
-
Method Details
-
entityTypes
- Parameters:
entityTypes
- the entity types to copy- Returns:
- this builder instance
-
conditions
- Parameters:
conditions
- the conditions to use when determining which entities of the given type to copy- Returns:
- this builder instance
-
batchSize
- Parameters:
batchSize
- the commit batch size- Returns:
- this buildr instance
- Throws:
IllegalArgumentException
- ifbatchSize
is not a positive integer
-
includePrimaryKeys
- Parameters:
includePrimaryKeys
- true if the primary key values should be included when copying- Returns:
- this builder instance
-
execute
void execute()Builds and executes this copy operation- Throws:
DatabaseException
- in case of an exception
-
build
EntityConnection.BatchCopy build()- Returns:
- a new
EntityConnection.BatchCopy
instance
-