Package net.hironico.minisql.ctrl
Class FileQueryResultCallable
java.lang.Object
net.hironico.minisql.ctrl.QueryResultCallable
net.hironico.minisql.ctrl.FileQueryResultCallable
- All Implemented Interfaces:
Callable<List<SQLResultSetTableModel>>
Same as QueryResultCallable but reads the contents of the given file path
to invoke the QueryResultCallable constructor.
Important: the given file contents will be executed in batchMode = true meaning that commit instructions will be invoked between each SQL statements separated by the "statement separator" property in the configuration of the connection.
Important: the given file contents will be executed in batchMode = true meaning that commit instructions will be invoked between each SQL statements separated by the "statement separator" property in the configuration of the connection.
-
Constructor Summary
ConstructorsConstructorDescriptionFileQueryResultCallable(Path filePath, DbConfig config) Loads the contents of the given file path and then pass it to the QueryResultCallable super implementation This constructor throws IOException id it is not possible to read from the given file path. -
Method Summary
Methods inherited from class net.hironico.minisql.ctrl.QueryResultCallable
addQueryHistoryListener, call, removeQueryHistoryListener
-
Constructor Details
-
FileQueryResultCallable
Loads the contents of the given file path and then pass it to the QueryResultCallable super implementation This constructor throws IOException id it is not possible to read from the given file path.- Parameters:
filePath- the file to load the query(ies) fromconfig- the DB config to use to run the queries of the given file path- Throws:
IOException- in case the file is not readable
-