public class MockExecuteContext extends Object
This context is passed to
MockDataProvider.execute(MockExecuteContext)
, as a context object
containing all relevant information about a given query execution.
MockDataProvider
Constructor and Description |
---|
MockExecuteContext(String[] sql,
Object[][] bindings)
Create a new mock execution context.
|
MockExecuteContext(String[] sql,
Object[][] bindings,
int autoGeneratedKeys)
Create a new mock execution context.
|
MockExecuteContext(String[] sql,
Object[][] bindings,
int[] columnIndexes)
Create a new mock execution context.
|
MockExecuteContext(String[] sql,
Object[][] bindings,
String[] columnNames)
Create a new mock execution context.
|
Modifier and Type | Method and Description |
---|---|
int |
autoGeneratedKeys()
The corresponding value from
MockStatement . |
boolean |
batch()
Whether this execution context is a from a batch statement.
|
Object[][] |
batchBindings()
Get all bind variables of a "single batch" statement.
|
boolean |
batchMultiple()
Whether this execution context is from a "multi batch" statement.
|
boolean |
batchSingle()
Whether this execution context is from a "single batch" statement.
|
String[] |
batchSQL()
Get all batch SQL statements of a "multi batch" statement.
|
Object[] |
bindings()
Get the single (or first "single batch") set of bind variables.
|
int[] |
columnIndexes()
The corresponding value from
MockStatement . |
String[] |
columnNames()
The corresponding value from
MockStatement . |
int[] |
outParameterTypes()
Get the types of registered out parameters, if any.
|
String |
sql()
Get the single (or first "multi batch") SQL statement.
|
public MockExecuteContext(String[] sql, Object[][] bindings)
sql
- The SQL statement(s)bindings
- The bind variable(s)public MockExecuteContext(String[] sql, Object[][] bindings, int autoGeneratedKeys)
sql
- The SQL statement(s)bindings
- The bind variable(s)autoGeneratedKeys
- The corresponding value from
MockStatement
public MockExecuteContext(String[] sql, Object[][] bindings, int[] columnIndexes)
sql
- The SQL statement(s)bindings
- The bind variable(s)columnIndexes
- The corresponding value from
MockStatement
public boolean batch()
public boolean batchSingle()
DSLContext.batch(Query)
public boolean batchMultiple()
DSLContext.batch(Query...)
public String[] batchSQL()
1
with the single statement.public Object[][] batchBindings()
1
with the bind variables of a single
statement.public String sql()
public Object[] bindings()
public int autoGeneratedKeys()
MockStatement
.MockStatement
.public int[] columnIndexes()
MockStatement
.MockStatement
.public String[] columnNames()
MockStatement
.MockStatement
.public int[] outParameterTypes()
Copyright © 2015. All Rights Reserved.