public class DeleteObjectQuery extends WriteObjectQuery
Purpose: Used for deleting objects.
Responsibilities: Extract primary key from object and delete it.
backupClone, object, objectChangeSet, primaryKey
forceBatchStatementExecution, modifyRow
accessor, arguments, argumentTypeNames, argumentTypes, argumentValues, CascadeAggregateDelete, CascadeAllParts, CascadeByMapping, CascadeDependentParts, cascadePolicy, CascadePrivateParts, descriptor, flushOnExecute, isPrepared, isUserDefined, name, NoCascading, properties, queryMechanism, session, sessionName, shouldBindAllParameters, shouldCacheStatement, shouldCloneCall, shouldMaintainCache, shouldPrepare, shouldUseWrapperPolicy, translationRow
False, True, Undefined
Constructor and Description |
---|
DeleteObjectQuery() |
DeleteObjectQuery(Call call) |
DeleteObjectQuery(Object objectToDelete) |
Modifier and Type | Method and Description |
---|---|
protected DatabaseQuery |
checkForCustomQuery(AbstractSession session,
AbstractRecord translationRow)
INTERNAL:
Check to see if a custom query should be used for this query.
|
void |
executeCommit()
INTERNAL:
Perform a delete.
|
protected Object |
executeInUnitOfWorkObjectLevelModifyQuery(UnitOfWorkImpl unitOfWork,
AbstractRecord translationRow)
INTERNAL:
Code was moved from UnitOfWork.internalExecuteQuery
|
void |
executeShallowWrite()
INTERNAL:
Perform a shallow delete.
|
boolean |
isDeleteObjectQuery()
PUBLIC:
Return if this is a delete object query.
|
protected void |
prepare()
INTERNAL:
Prepare the receiver for execution in a session.
|
protected void |
prepareCustomQuery(DatabaseQuery customQuery)
INTERNAL:
Set the properties needed to be cascaded into the custom query.
|
void |
prepareForExecution()
INTERNAL:
Prepare the receiver for execution in a session.
|
doesObjectExist, executeCommitWithChangeSet, executeDatabaseQuery, isWriteObjectQuery, shouldDependentObjectBeDeleted, shouldObjectBeDeleted
checkDescriptor, executeInUnitOfWork, getBackupClone, getObject, getObjectChangeSet, getPrimaryKey, getReferenceClass, getReferenceClassName, isObjectLevelModifyQuery, setBackupClone, setObject, setObjectChangeSet, setPrimaryKey, toString
forceBatchStatementExecution, getModifyRow, isModifyQuery, setForceBatchStatementExecution, setModifyRow
addArgument, addArgument, addArgument, addArgumentByTypeName, addArgumentValue, addArgumentValues, addCall, addStatement, bindAllParameters, buildSelectionCriteria, cacheStatement, cascadeAllParts, cascadeByMapping, cascadeOnlyDependentParts, cascadePrivateParts, checkEarlyReturn, checkPrepare, clone, clonedQueryExecutionComplete, convertClassNamesToClasses, deploymentSetShouldMaintainCache, deploymentShouldMaintainCache, dontBindAllParameters, dontCacheStatement, dontCascadeParts, dontMaintainCache, execute, getAccessor, getArguments, getArgumentTypeNames, getArgumentTypes, getArgumentValues, getCall, getCascadePolicy, getDatasourceCall, getDatasourceCalls, getDescriptor, getEJBQLString, getFlushOnExecute, getName, getProperties, getProperty, getQueryMechanism, getSelectionCriteria, getSession, getSessionName, getShouldBindAllParameters, getSQLStatement, getSQLString, getSQLStrings, getTranslatedSQLString, getTranslatedSQLStrings, getTranslationRow, hasAccessor, hasProperties, hasQueryMechanism, hasSessionName, ignoreBindAllParameters, ignoreCacheStatement, isCallQuery, isCascadeOfAggregateDelete, isDataModifyQuery, isDataReadQuery, isDeleteAllQuery, isExpressionQuery, isInsertObjectQuery, isModifyAllQuery, isObjectBuildingQuery, isObjectLevelReadQuery, isPrepared, isReadAllQuery, isReadObjectQuery, isReadQuery, isReportQuery, isSQLCallQuery, isUpdateAllQuery, isUpdateObjectQuery, isUserDefined, maintainCache, prepareCall, prepareForRemoteExecution, removeProperty, rowFromArguments, setAccessor, setArguments, setArgumentTypeNames, setArgumentTypes, setArgumentValues, setCall, setCascadePolicy, setDatasourceCall, setDescriptor, setEJBQLString, setFlushOnExecute, setIsPrepared, setIsUserDefined, setName, setProperties, setProperty, setQueryMechanism, setSelectionCriteria, setSession, setSessionName, setShouldBindAllParameters, setShouldBindAllParameters, setShouldCacheStatement, setShouldMaintainCache, setShouldPrepare, setShouldUseWrapperPolicy, setSQLStatement, setSQLString, setTranslationRow, shouldBindAllParameters, shouldCacheStatement, shouldCascadeAllParts, shouldCascadeByMapping, shouldCascadeOnlyDependentParts, shouldCascadeParts, shouldCascadePrivateParts, shouldCloneCall, shouldIgnoreBindAllParameters, shouldIgnoreCacheStatement, shouldMaintainCache, shouldPrepare, shouldUseWrapperPolicy
public DeleteObjectQuery()
public DeleteObjectQuery(Object objectToDelete)
public DeleteObjectQuery(Call call)
protected DatabaseQuery checkForCustomQuery(AbstractSession session, AbstractRecord translationRow)
checkForCustomQuery
in class DatabaseQuery
public void executeCommit() throws DatabaseException
executeCommit
in class WriteObjectQuery
DatabaseException
protected Object executeInUnitOfWorkObjectLevelModifyQuery(UnitOfWorkImpl unitOfWork, AbstractRecord translationRow) throws DatabaseException, OptimisticLockException
executeInUnitOfWorkObjectLevelModifyQuery
in class ObjectLevelModifyQuery
unitOfWork
- translationRow
- DatabaseException
OptimisticLockException
public void executeShallowWrite()
executeShallowWrite
in class WriteObjectQuery
public boolean isDeleteObjectQuery()
isDeleteObjectQuery
in class DatabaseQuery
protected void prepare()
prepare
in class ObjectLevelModifyQuery
protected void prepareCustomQuery(DatabaseQuery customQuery)
prepareCustomQuery
in class DatabaseQuery
public void prepareForExecution() throws QueryException
prepareForExecution
in class WriteObjectQuery
QueryException
Copyright © 2024. All rights reserved.