class CompositeQuery extends java.lang.Object implements Query
| Modifier and Type | Field and Description |
|---|---|
private int[] |
offsets |
private SimpleQuery[] |
subqueries |
| Constructor and Description |
|---|
CompositeQuery(SimpleQuery[] subqueries,
int[] offsets) |
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Close this query and free any server-side resources associated with it.
|
ParameterList |
createParameterList()
Create a ParameterList suitable for storing parameters associated with this Query.
|
int |
getBatchSize()
Get the number of times this Query has been batched.
|
java.lang.String |
getNativeSql()
Returns SQL in native for database format.
|
java.util.Map<java.lang.String,java.lang.Integer> |
getResultSetColumnNameIndexMap()
Get a map that a result set can use to find the index associated to a name.
|
SqlCommand |
getSqlCommand()
Returns properties of the query (sql keyword, and some other parsing info).
|
Query[] |
getSubqueries()
Return a list of the Query objects that make up this query.
|
boolean |
isEmpty() |
boolean |
isStatementDescribed() |
java.lang.String |
toString() |
java.lang.String |
toString(ParameterList parameters)
Stringize this query to a human-readable form, substituting particular parameter values for
parameter placeholders.
|
private final SimpleQuery[] subqueries
private final int[] offsets
CompositeQuery(SimpleQuery[] subqueries, int[] offsets)
public ParameterList createParameterList()
QueryCreate a ParameterList suitable for storing parameters associated with this Query.
If this query has no parameters, a ParameterList will be returned, but it may be a shared immutable object. If this query does have parameters, the returned ParameterList is a new list, unshared by other callers.
createParameterList in interface Querypublic java.lang.String toString(ParameterList parameters)
QuerytoString in interface Queryparameters - a ParameterList returned by this Query's Query.createParameterList() method,
or null to leave the parameter placeholders unsubstituted.public java.lang.String getNativeSql()
QuerygetNativeSql in interface Querypublic SqlCommand getSqlCommand()
QuerygetSqlCommand in interface Querypublic java.lang.String toString()
toString in class java.lang.Objectpublic void close()
QueryClose this query and free any server-side resources associated with it. The resources may not be immediately deallocated, but closing a Query may make the deallocation more prompt.
A closed Query should not be executed.
public Query[] getSubqueries()
QuerygetSubqueries in interface Querynull if this object is already a
single-statement query.public boolean isStatementDescribed()
isStatementDescribed in interface Querypublic int getBatchSize()
QuerygetBatchSize in interface QueryaddBatch() has been called.public java.util.Map<java.lang.String,java.lang.Integer> getResultSetColumnNameIndexMap()
QuerygetResultSetColumnNameIndexMap in interface Query