public class MultiVariableIntExecutionResult extends Object implements MultiExecutionResult
Modifier and Type | Field and Description |
---|---|
Deque<ExecutionResult> |
cachedExecutionResults |
Constructor and Description |
---|
MultiVariableIntExecutionResult(Statement statement,
int size,
int fetchSize,
boolean selectPossible)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
addResult(ExecutionResult executionResult) |
void |
addResultSet(MariaSelectResultSet result,
boolean moreResultAvailable)
Add a resultSet information.
|
void |
addStats(long affectedRows,
long insertId,
boolean moreResultAvailable)
Add execution statistics.
|
void |
addStatsError() |
void |
close()
Close resultset if needed.
|
int[] |
getAffectedRows()
Get update array.
|
Deque<ExecutionResult> |
getCachedExecutionResults() |
int |
getFetchSize() |
int |
getFirstAffectedRows() |
long[] |
getInsertIds()
Get insert ids.
|
MariaSelectResultSet |
getResultSet() |
Statement |
getStatement() |
boolean |
hasMoreResultAvailable() |
boolean |
hasMoreThanOneAffectedRows() |
boolean |
isCanHaveCallableResultset() |
boolean |
isSelectPossible() |
boolean |
isSingleExecutionResult() |
void |
setFetchSize(int fetchSize) |
protected void |
setMoreResultAvailable(boolean moreResultAvailable) |
void |
updateResultsForRewrite(int waitedSize,
boolean hasException)
Set resultSet for rewrite queries.
|
void |
updateResultsMultiple(int waitedSize,
boolean hasException)
Set update resultSet right on multiple rewrite.
|
public Deque<ExecutionResult> cachedExecutionResults
public MultiVariableIntExecutionResult(Statement statement, int size, int fetchSize, boolean selectPossible)
statement
- current statementsize
- initial data sizefetchSize
- resultet fetch sizeselectPossible
- is select command possiblepublic void addResultSet(MariaSelectResultSet result, boolean moreResultAvailable)
addResultSet
in interface ExecutionResult
result
- resultset implementationmoreResultAvailable
- is there additional packetpublic void addStats(long affectedRows, long insertId, boolean moreResultAvailable)
addStats
in interface ExecutionResult
affectedRows
- number of affected rowsinsertId
- primary keymoreResultAvailable
- is there additional packetpublic long[] getInsertIds()
getInsertIds
in interface ExecutionResult
public int[] getAffectedRows()
getAffectedRows
in interface MultiExecutionResult
public boolean hasMoreThanOneAffectedRows()
hasMoreThanOneAffectedRows
in interface ExecutionResult
public int getFirstAffectedRows()
getFirstAffectedRows
in interface ExecutionResult
getFirstAffectedRows
in interface MultiExecutionResult
public void addStatsError()
public void updateResultsForRewrite(int waitedSize, boolean hasException)
updateResultsForRewrite
in interface MultiExecutionResult
waitedSize
- batchSizehasException
- has exceptionpublic void updateResultsMultiple(int waitedSize, boolean hasException)
updateResultsMultiple
in interface MultiExecutionResult
waitedSize
- batchSizehasException
- has exceptionpublic MariaSelectResultSet getResultSet()
getResultSet
in interface ExecutionResult
public Statement getStatement()
getStatement
in interface ExecutionResult
public boolean hasMoreResultAvailable()
hasMoreResultAvailable
in interface ExecutionResult
protected void setMoreResultAvailable(boolean moreResultAvailable)
public int getFetchSize()
getFetchSize
in interface ExecutionResult
public void setFetchSize(int fetchSize)
setFetchSize
in interface ExecutionResult
public void close() throws SQLException
close
in interface ExecutionResult
SQLException
- if exception occur during resultset close.public boolean isSelectPossible()
isSelectPossible
in interface ExecutionResult
public boolean isCanHaveCallableResultset()
isCanHaveCallableResultset
in interface ExecutionResult
public Deque<ExecutionResult> getCachedExecutionResults()
getCachedExecutionResults
in interface ExecutionResult
public void addResult(ExecutionResult executionResult)
public boolean isSingleExecutionResult()
isSingleExecutionResult
in interface ExecutionResult
Copyright © 2016. All rights reserved.