Package com.mysql.cj.xdevapi
Class SelectStatementImpl
java.lang.Object
com.mysql.cj.xdevapi.PreparableStatement<RES_T>
com.mysql.cj.xdevapi.FilterableStatement<SelectStatement,RowResult>
com.mysql.cj.xdevapi.SelectStatementImpl
- All Implemented Interfaces:
SelectStatement
,Statement<SelectStatement,RowResult>
public class SelectStatementImpl extends FilterableStatement<SelectStatement,RowResult> implements SelectStatement
SelectStatement
implementation.-
Nested Class Summary
Nested classes/interfaces inherited from class com.mysql.cj.xdevapi.PreparableStatement
PreparableStatement.PreparableStatementFinalizer, PreparableStatement.PreparedState
Nested classes/interfaces inherited from interface com.mysql.cj.xdevapi.Statement
Statement.LockContention
-
Field Summary
Fields inherited from class com.mysql.cj.xdevapi.PreparableStatement
mysqlxSession, preparedState, preparedStatementId
-
Method Summary
Modifier and Type Method Description java.util.concurrent.CompletableFuture<RowResult>
executeAsync()
Execute the statement asynchronously.protected RowResult
executePreparedStatement()
Executes a previously server-prepared statement.protected RowResult
executeStatement()
Executes the statement directly (non-prepared).FilterParams
getFilterParams()
ReturnFilterParams
defined for this statement.protected XMessage
getPrepareStatementXMessage()
Returns theXMessage
needed to prepare this statement.SelectStatement
groupBy(java.lang.String... groupBy)
Add/replace the aggregation fields for this query.SelectStatement
having(java.lang.String having)
Add/replace the aggregate criteria for this query.SelectStatement
lockExclusive()
Locks matching rows exclusively so no other transactions can read or write to them.SelectStatement
lockExclusive(Statement.LockContention lockContention)
Locks matching rows exclusively so no other transactions can read or write to them, using the provided lock contention option.SelectStatement
lockShared()
Locks matching rows against updates.SelectStatement
lockShared(Statement.LockContention lockContention)
Locks matching rows against updates using the provided lock contention option.Methods inherited from class com.mysql.cj.xdevapi.FilterableStatement
bind, clearBindings, isRelational, limit, offset, orderBy, sort, where
Methods inherited from class com.mysql.cj.xdevapi.PreparableStatement
deallocatePrepared, execute, getMessageBuilder, resetPrepareState, setReprepareState
-
Method Details
-
executeStatement
Description copied from class:PreparableStatement
Executes the statement directly (non-prepared). Implementation is dependent on the statement type.- Specified by:
executeStatement
in classPreparableStatement<RowResult>
- Returns:
- the object returned from the lower level statement execution
-
getPrepareStatementXMessage
Description copied from class:PreparableStatement
Returns theXMessage
needed to prepare this statement. Implementation is dependent on the statement type.- Specified by:
getPrepareStatementXMessage
in classPreparableStatement<RowResult>
- Returns:
- the
XMessage
that prepares this statement
-
executePreparedStatement
Description copied from class:PreparableStatement
Executes a previously server-prepared statement. Implementation is dependent on the statement type.- Specified by:
executePreparedStatement
in classPreparableStatement<RowResult>
- Returns:
- the object returned from the lower level statement execution
-
executeAsync
Description copied from interface:Statement
Execute the statement asynchronously.- Specified by:
executeAsync
in interfaceStatement<SelectStatement,RowResult>
- Returns:
CompletableFuture
for result
-
groupBy
Description copied from interface:SelectStatement
Add/replace the aggregation fields for this query.- Specified by:
groupBy
in interfaceSelectStatement
- Parameters:
groupBy
- groupBy expression- Returns:
SelectStatement
-
having
Description copied from interface:SelectStatement
Add/replace the aggregate criteria for this query.- Specified by:
having
in interfaceSelectStatement
- Parameters:
having
- having expression- Returns:
SelectStatement
-
getFilterParams
Description copied from interface:SelectStatement
ReturnFilterParams
defined for this statement.- Specified by:
getFilterParams
in interfaceSelectStatement
- Returns:
FilterParams
-
lockShared
Description copied from interface:SelectStatement
Locks matching rows against updates.- Specified by:
lockShared
in interfaceSelectStatement
- Returns:
SelectStatement
-
lockShared
Description copied from interface:SelectStatement
Locks matching rows against updates using the provided lock contention option.- Specified by:
lockShared
in interfaceSelectStatement
- Parameters:
lockContention
- TheStatement.LockContention
value to set.- Returns:
SelectStatement
-
lockExclusive
Description copied from interface:SelectStatement
Locks matching rows exclusively so no other transactions can read or write to them.- Specified by:
lockExclusive
in interfaceSelectStatement
- Returns:
SelectStatement
-
lockExclusive
Description copied from interface:SelectStatement
Locks matching rows exclusively so no other transactions can read or write to them, using the provided lock contention option.- Specified by:
lockExclusive
in interfaceSelectStatement
- Parameters:
lockContention
- TheStatement.LockContention
value to set.- Returns:
SelectStatement
-