DeleteBatchQuery (cayenne-doc: Cayenne Documentation 5.0-M2 API)
Description: declaration: package: org.apache.cayenne.query, class: DeleteBatchQuery

# Class DeleteBatchQuery

java.lang.Object
org.apache.cayenne.query.BatchQuery
org.apache.cayenne.query.DeleteBatchQuery

All Implemented Interfaces:
  `Serializable, Query`

public class DeleteBatchQuery extends BatchQuery
Batched delete query.

See Also:
  - Serialized Form

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `protected boolean`
  `usingOptimisticLocking`

  ### Fields inherited from class BatchQuery

  `dbAttributes, dbEntity, rows`
  Modifier and Type
  Field
  Description
  `protected List<DbAttribute>`
  `dbAttributes`
  `protected DbEntity`
  `dbEntity`
  `protected List<BatchQueryRow>`
  `rows`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `DeleteBatchQuery(DbEntity dbEntity, List<DbAttribute> qualifierAttributes, Collection<String> nullQualifierNames, int batchCapacity)`
  Creates new DeleteBatchQuery.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `add(Map<String,Object> objectId)`
  `boolean`
  `isNull(DbAttribute attribute)`
  Returns true if a given attribute always has a null value in the batch.
  `boolean`
  `isUsingOptimisticLocking()`
  Returns true if the batch query uses optimistic locking.
  `void`
  `setUsingOptimisticLocking(boolean usingOptimisticLocking)`

  ### Methods inherited from class BatchQuery

  `createSQLAction, getDbAttributes, getDbEntity, getMetaData, getRows, route`
  Modifier and Type
  Method
  Description
  `SQLAction`
  `createSQLAction(SQLActionVisitor visitor)`
  Calls "batchAction" on the visitor.
  `List<DbAttribute>`
  `getDbAttributes()`
  Returns a list of DbAttributes describing batch parameters.
  `DbEntity`
  `getDbEntity()`
  Returns a DbEntity associated with this batch.
  `QueryMetadata`
  `getMetaData(EntityResolver resolver)`
  Returns default select parameters.
  `List<BatchQueryRow>`
  `getRows()`
  `void`
  `route(QueryRouter router, EntityResolver resolver, Query substitutedQuery)`
  A callback method invoked by Cayenne during the routing phase of the query execution.

  ### Methods inherited from class Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## 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

    public boolean isNull(DbAttribute attribute)
    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:
      `isUsingOptimisticLocking` in class `BatchQuery`
    Since:
      1.2

  - ### setUsingOptimisticLocking

    public void setUsingOptimisticLocking(boolean usingOptimisticLocking)
    Since:
      1.2

  - ### add

    public void add(Map<String,Object> objectId)