- java.lang.Object
- 
- org.jooq.tools.jdbc.MockExecuteContext
 
- 
 public class MockExecuteContext extends Object A mock execution context.This context is passed to MockDataProvider.execute(MockExecuteContext), as a context object containing all relevant information about a given query execution.- Author:
- Lukas Eder
- See Also:
- MockDataProvider
 
- 
- 
Constructor SummaryConstructors Constructor 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.
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description intautoGeneratedKeys()The corresponding value fromMockStatement.booleanbatch()Whether this execution context is a from a batch statement.Object[][]batchBindings()Get all bind variables of a "single batch" statement.booleanbatchMultiple()Whether this execution context is from a "multi batch" statement.booleanbatchSingle()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 fromMockStatement.String[]columnNames()The corresponding value fromMockStatement.int[]outParameterTypes()Get the types of registered out parameters, if any.Stringsql()Get the single (or first "multi batch") SQL statement.
 
- 
- 
- 
Constructor Detail- 
MockExecuteContextpublic MockExecuteContext(String[] sql, Object[][] bindings) Create a new mock execution context.- Parameters:
- sql- The SQL statement(s)
- bindings- The bind variable(s)
 
 - 
MockExecuteContextpublic MockExecuteContext(String[] sql, Object[][] bindings, int autoGeneratedKeys) Create a new mock execution context.- Parameters:
- sql- The SQL statement(s)
- bindings- The bind variable(s)
- autoGeneratedKeys- The corresponding value from- MockStatement
 
 - 
MockExecuteContextpublic MockExecuteContext(String[] sql, Object[][] bindings, int[] columnIndexes) Create a new mock execution context.- Parameters:
- sql- The SQL statement(s)
- bindings- The bind variable(s)
- columnIndexes- The corresponding value from- MockStatement
 
 
- 
 - 
Method Detail- 
batchpublic boolean batch() Whether this execution context is a from a batch statement.- Returns:
- Whether this execution context is a from a batch statement.
 
 - 
batchSinglepublic boolean batchSingle() Whether this execution context is from a "single batch" statement.- Returns:
- Whether this execution context is from a "single batch" statement.
- See Also:
- DSLContext.batch(Query)
 
 - 
batchMultiplepublic boolean batchMultiple() Whether this execution context is from a "multi batch" statement.- Returns:
- Whether this execution context is from a "multi batch" statement.
- See Also:
- DSLContext.batch(Query...)
 
 - 
batchSQLpublic String[] batchSQL() Get all batch SQL statements of a "multi batch" statement.- Returns:
- All batch SQL statements of a "multi batch" statement, or an
         array of length 1with the single statement.
 
 - 
batchBindingspublic Object[][] batchBindings() Get all bind variables of a "single batch" statement.- Returns:
- All bind variables of a "single batch" statment, or an array of
         length 1with the bind variables of a single statement.
 
 - 
sqlpublic String sql() Get the single (or first "multi batch") SQL statement.- Returns:
- The single (or first "multi batch") SQL statement.
 
 - 
bindingspublic Object[] bindings() Get the single (or first "single batch") set of bind variables.- Returns:
- The single (or first "single batch") set of bind variables.
 
 - 
autoGeneratedKeyspublic int autoGeneratedKeys() The corresponding value fromMockStatement.- Returns:
- The corresponding value from MockStatement.
 
 - 
columnIndexespublic int[] columnIndexes() The corresponding value fromMockStatement.- Returns:
- The corresponding value from MockStatement.
 
 - 
columnNamespublic String[] columnNames() The corresponding value fromMockStatement.- Returns:
- The corresponding value from MockStatement.
 
 - 
outParameterTypespublic int[] outParameterTypes() Get the types of registered out parameters, if any.- Returns:
- the types of registered out parameters, if any.
 
 
- 
 
-