Class DeleteBatchQuery
java.lang.Object
org.apache.cayenne.query.BatchQuery
org.apache.cayenne.query.DeleteBatchQuery
- All Implemented Interfaces:
Serializable, Query
-
Field Summary
FieldsFields inherited from class BatchQuery
dbAttributes, dbEntity, rowsModifier and TypeFieldDescriptionprotected List<DbAttribute> protected DbEntityprotected List<BatchQueryRow> -
Constructor Summary
ConstructorsConstructorDescriptionDeleteBatchQuery(DbEntity dbEntity, List<DbAttribute> qualifierAttributes, Collection<String> nullQualifierNames, int batchCapacity) Creates new DeleteBatchQuery. -
Method Summary
Modifier and TypeMethodDescriptionvoidbooleanisNull(DbAttribute attribute) Returns true if a given attribute always has a null value in the batch.booleanReturns true if the batch query uses optimistic locking.voidsetUsingOptimisticLocking(boolean usingOptimisticLocking) Methods inherited from class BatchQuery
createSQLAction, getDbAttributes, getDbEntity, getMetaData, getRows, routeModifier and TypeMethodDescriptioncreateSQLAction(SQLActionVisitor visitor) Calls "batchAction" on the visitor.Returns a list of DbAttributes describing batch parameters.Returns a DbEntity associated with this batch.getMetaData(EntityResolver resolver) Returns default select parameters.getRows()voidroute(QueryRouter router, EntityResolver resolver, Query substitutedQuery) A callback method invoked by Cayenne during the routing phase of the query execution.
-
Field Details
-
usingOptimisticLocking
protected boolean usingOptimisticLocking
-
-
Constructor Details
-
DeleteBatchQuery
public DeleteBatchQuery(DbEntity dbEntity, List<DbAttribute> qualifierAttributes, Collection<String> nullQualifierNames, int batchCapacity) Creates new DeleteBatchQuery.- Parameters:
dbEntity- Table or view to delete.qualifierAttributes- DbAttributes used in the WHERE clause.nullQualifierNames- DbAttribute names in the WHERE clause that have null values.batchCapacity- Estimated size of the batch.
-
-
Method Details
-
isNull
Returns true if a given attribute always has a null value in the batch.- Since:
- 1.2
-
isUsingOptimisticLocking
public boolean isUsingOptimisticLocking()Returns true if the batch query uses optimistic locking.- Overrides:
isUsingOptimisticLockingin classBatchQuery- Since:
- 1.2
-
setUsingOptimisticLocking
public void setUsingOptimisticLocking(boolean usingOptimisticLocking) - Since:
- 1.2
-
add
-