|
Oracle Application Server TopLink API Reference 10g Release 2 (10.1.2) B15903-01 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object
oracle.toplink.queryframework.DatabaseQuery
Purpose: Abstract class for all database query objects. DatabaseQuery is a visible class to the TopLink user. Users create an appropriate query by creating an instance of a concrete subclasses of DatabaseQuery.
Responsibilities:
Field Summary | |
static int |
CascadeAggregateDelete |
static int |
CascadeAllParts |
static int |
CascadeDependentParts |
static int |
CascadePrivateParts |
static int |
NoCascading |
static java.lang.String |
QUERY_PREPARE |
Constructor Summary | |
DatabaseQuery() PUBLIC: Initialize the state of the query |
Method Summary | |
void |
addArgument(java.lang.String argumentName) PUBLIC: Add the argument named argumentName. |
void |
addArgument(java.lang.String argumentName, java.lang.Class type) PUBLIC: Add the argument named argumentName and its class type. |
void |
addArgument(java.lang.String argumentName, java.lang.String typeAsString) PUBLIC: Add the argument named argumentName and its class type. |
void |
addArgumentValue(java.lang.String argumentValue) PUBLIC: Add the argumentValue named argumentName. |
void |
addArgumentValues(java.util.Vector theArgumentValues) PUBLIC: Add the argumentValues to the query |
void |
addCall(Call call) PUBLIC: Used to define a store procedure or SQL query. |
void |
addStatement(oracle.toplink.internal.expressions.SQLStatement statement) PUBLIC: Used to define a statement level query. |
void |
bindAllParameters() PUBLIC: Bind all arguments to any SQL statement. |
void |
cacheStatement() PUBLIC: Cache the prepared statements, this requires full parameter binding as well. |
void |
cascadeAllParts() PUBLIC: Cascade the query and its properties on the queries object(s) and all objects related to the queries object(s). |
void |
cascadePrivateParts() PUBLIC: Cascade the query and its properties on the queries object(s) and all privately owned objects related to the queries object(s). |
void |
dontBindAllParameters() PUBLIC: Do not Bind all arguments to any SQL statement. |
void |
dontCacheStatement() PUBLIC: Dont cache the prepared statements, this requires full parameter binding as well. |
void |
dontCascadeParts() PUBLIC: Do not cascade the query and its properties on the queries object(s) relationships. |
void |
dontMaintainCache() PUBLIC: Set for the identity map (cache) to be ignored completely. |
oracle.toplink.internal.databaseaccess.DatabaseCall |
getCall() ADVANCED: Return the call for this query. |
java.lang.String |
getEJBQLString() PUBLIC: Return the SQL string of the query. |
java.lang.String |
getHintString() PUBLIC: Return the current Oracle Hint string of the query |
java.lang.String |
getName() PUBLIC: Return the name of the query |
int |
getQueryTimeout() PUBLIC: Return the number of seconds the driver will wait for a Statement to execute to the given number of seconds. |
QueryRedirector |
getRedirector() PUBLIC: Return the query redirector. |
java.lang.Class |
getReferenceClass() PUBLIC: Return the domain class associated with this query. |
Expression |
getSelectionCriteria() PUBLIC: Return the selection criteria of the query. |
java.lang.String |
getSessionName() PUBLIC: Return the name of the session that the query should be executed under. |
oracle.toplink.internal.expressions.SQLStatement |
getSQLStatement() PUBLIC: Return the SQL statement of the query. |
java.lang.String |
getSQLString() PUBLIC: Return the SQL string of the query. |
java.lang.String |
getTranslatedSQLString(oracle.toplink.publicinterface.Session session, DatabaseRow translationRow) ADVANCED: This can be used to access a queries translated SQL if they have been prepared, (i.e. query.prepareCall()). |
boolean |
hasSessionName() PUBLIC: Return if a name of the session that the query should be executed under has been specified. |
void |
ignoreBindAllParameters() PUBLIC: Session's shouldBindAllParameters() defines whether to bind or not (default setting) |
void |
ignoreCacheStatement() PUBLIC: Session's shouldCacheAllStatements() defines whether to cache or not (default setting) |
boolean |
isCallQuery() PUBLIC: Return true if this query uses an SQL, stored procedure, or SDK call. |
boolean |
isDataModifyQuery() PUBLIC: Return if this is a data modify query. |
boolean |
isDataReadQuery() PUBLIC: Return if this is a data read query. |
boolean |
isDeleteObjectQuery() PUBLIC: Return if this is a delete object query. |
boolean |
isExpressionQuery() PUBLIC: Return true if this query uses an expression query mechanism |
boolean |
isModifyQuery() PUBLIC: Return if this is a modify query. |
boolean |
isObjectLevelModifyQuery() PUBLIC: Return if this is an object level modify query. |
boolean |
isObjectLevelReadQuery() PUBLIC: Return if this is an object level read query. |
boolean |
isReadAllQuery() PUBLIC: Return if this is a read all query. |
boolean |
isReadObjectQuery() PUBLIC: Return if this is a read object query. |
boolean |
isReadQuery() PUBLIC: Return if this is a read query. |
boolean |
isReportQuery() PUBLIC: Return if this is a report query. |
boolean |
isSQLCallQuery() PUBLIC: Return true if this query uses an SQL query mechanism . |
boolean |
isWriteObjectQuery() PUBLIC: Return if this is a write object query. |
void |
maintainCache() PUBLIC: Set for the identity map (cache) to be maintained. |
void |
prepareCall(oracle.toplink.publicinterface.Session session, DatabaseRow translationRow) ADVANCED: Pre-generate the call/SQL for the query. |
void |
setCall(Call call) PUBLIC: Used to define a store procedure or SQL query. |
void |
setEJBQLString(java.lang.String ejbqlString) PUBLIC: To any user of this object. |
void |
setHintString(java.lang.String newHintString) PUBLIC: Used to set the Oracle Hint string on the query. |
void |
setName(java.lang.String queryName) PUBLIC: Set the query's name. |
void |
setQueryTimeout(int queryTimeout) PUBLIC: Set the number of seconds the driver will wait for a Statement to execute to the given number of seconds. |
void |
setRedirector(QueryRedirector redirector) PUBLIC: Set the query redirector. |
void |
setSelectionCriteria(Expression expression) PUBLIC: To any user of this object. |
void |
setSessionName(java.lang.String sessionName) PUBLIC: Set the name of the session that the query should be executed under. |
void |
setShouldBindAllParameters(boolean shouldBindAllParameters) PUBLIC: Bind all arguments to any SQL statement. |
void |
setShouldCacheStatement(boolean shouldCacheStatement) PUBLIC: Cache the prepared statements, this requires full parameter binding as well. |
void |
setShouldMaintainCache(boolean shouldMaintainCache) PUBLIC: Set if the identity map (cache) should be used or not. |
void |
setShouldPrepare(boolean shouldPrepare) PUBLIC: Set if the query should be prepared. |
void |
setShouldUseWrapperPolicy(boolean shouldUseWrapperPolicy) ADVANCED: The wrapper policy can be enable on a query. |
void |
setSQLStatement(oracle.toplink.internal.expressions.SQLStatement sqlStatement) PUBLIC: To any user of this object. |
void |
setSQLString(java.lang.String sqlString) PUBLIC: To any user of this object. |
boolean |
shouldBindAllParameters() PUBLIC: Bind all arguments to any SQL statement. |
boolean |
shouldCacheStatement() PUBLIC: Cache the prepared statements, this requires full parameter binding as well. |
boolean |
shouldCascadeAllParts() PUBLIC: Flag used to determine if all parts should be cascaded |
boolean |
shouldCascadeParts() PUBLIC: Flag used to determine if any parts should be cascaded |
boolean |
shouldCascadePrivateParts() PUBLIC: Flag used to determine if any private parts should be cascaded |
boolean |
shouldIgnoreBindAllParameters() PUBLIC: Local shouldBindAllParameters() should be ignored, Session's shouldBindAllParameters() should be used. |
boolean |
shouldIgnoreCacheStatement() PUBLIC: Local shouldCacheStatement() should be ignored, Session's shouldCacheAllStatements() should be used. |
boolean |
shouldMaintainCache() PUBLIC: Return if the identity map (cache) should be used or not. |
boolean |
shouldPrepare() PUBLIC: Return if the query should be prepared. |
boolean |
shouldUseWrapperPolicy() ADVANCED: The wrapper policy can be enabled on a query. |
java.lang.String |
toString() |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final java.lang.String QUERY_PREPARE
public static final int NoCascading
public static final int CascadePrivateParts
public static final int CascadeAllParts
public static final int CascadeDependentParts
public static final int CascadeAggregateDelete
Constructor Detail |
public DatabaseQuery()
Method Detail |
public void addArgument(java.lang.String argumentName)
public void addArgument(java.lang.String argumentName, java.lang.Class type)
public void addArgument(java.lang.String argumentName, java.lang.String typeAsString)
public void addArgumentValue(java.lang.String argumentValue)
public void addArgumentValues(java.util.Vector theArgumentValues)
public void addCall(Call call)
public void addStatement(oracle.toplink.internal.expressions.SQLStatement statement)
public void bindAllParameters()
public void cacheStatement()
public void cascadeAllParts()
public void cascadePrivateParts()
public void dontBindAllParameters()
public void dontCacheStatement()
public void dontCascadeParts()
public void dontMaintainCache()
public oracle.toplink.internal.databaseaccess.DatabaseCall getCall()
prepareCall(Session, DatabaseRow);
public java.lang.String getName()
public int getQueryTimeout()
public QueryRedirector getRedirector()
QueryRedirector
public java.lang.Class getReferenceClass()
public Expression getSelectionCriteria()
public java.lang.String getSessionName()
public oracle.toplink.internal.expressions.SQLStatement getSQLStatement()
public java.lang.String getEJBQLString()
prepareCall(Session, DatabaseRow)
public java.lang.String getHintString()
public java.lang.String getSQLString()
prepareCall(Session, DatabaseRow)
public java.lang.String getTranslatedSQLString(oracle.toplink.publicinterface.Session session, DatabaseRow translationRow)
prepareCall(Session, DatabaseRow)
public boolean hasSessionName()
public void ignoreBindAllParameters()
public void ignoreCacheStatement()
public boolean isCallQuery()
public boolean isDataModifyQuery()
public boolean isDataReadQuery()
public boolean isDeleteObjectQuery()
public boolean isExpressionQuery()
public boolean isModifyQuery()
public boolean isObjectLevelModifyQuery()
public boolean isObjectLevelReadQuery()
public boolean isReadAllQuery()
public boolean isReadObjectQuery()
public boolean isReadQuery()
public boolean isReportQuery()
public boolean isSQLCallQuery()
public boolean isWriteObjectQuery()
public void maintainCache()
public void prepareCall(oracle.toplink.publicinterface.Session session, DatabaseRow translationRow) throws QueryException
QueryException
getCall()
, getSQLString()
, getTranslatedSQLString(Session, DatabaseRow)
public void setCall(Call call)
public void setEJBQLString(java.lang.String ejbqlString)
public void setHintString(java.lang.String newHintString)
public void setName(java.lang.String queryName)
public void setQueryTimeout(int queryTimeout)
public void setRedirector(QueryRedirector redirector)
QueryRedirector
public void setSelectionCriteria(Expression expression)
public void setSessionName(java.lang.String sessionName)
public void setShouldBindAllParameters(boolean shouldBindAllParameters)
public void setShouldCacheStatement(boolean shouldCacheStatement)
public void setShouldMaintainCache(boolean shouldMaintainCache)
public void setShouldPrepare(boolean shouldPrepare)
These queries include:
public void setShouldUseWrapperPolicy(boolean shouldUseWrapperPolicy)
public void setSQLStatement(oracle.toplink.internal.expressions.SQLStatement sqlStatement)
public void setSQLString(java.lang.String sqlString)
public boolean shouldBindAllParameters()
public boolean shouldCacheStatement()
public boolean shouldCascadeAllParts()
public boolean shouldCascadeParts()
public boolean shouldCascadePrivateParts()
public boolean shouldIgnoreBindAllParameters()
public boolean shouldIgnoreCacheStatement()
public boolean shouldMaintainCache()
public boolean shouldPrepare()
These queries include:
public boolean shouldUseWrapperPolicy()
public java.lang.String toString()
|
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |