Search in sources :

Example 1 with ResourceManager

use of io.vertigo.core.resource.ResourceManager in project vertigo by KleeGroup.

the class NameSpace2JavaTest method execSqlScript.

private void execSqlScript(final String sqlScript, final App app) {
    final ResourceManager resourceManager = app.getComponentSpace().resolve(ResourceManager.class);
    final SqlDataBaseManager sqlDataBaseManager = app.getComponentSpace().resolve(SqlDataBaseManager.class);
    final SqlConnection connection = sqlDataBaseManager.getConnectionProvider(SqlDataBaseManager.MAIN_CONNECTION_PROVIDER_NAME).obtainConnection();
    DataBaseScriptUtil.execSqlScript(connection, sqlScript, resourceManager, sqlDataBaseManager);
}
Also used : SqlDataBaseManager(io.vertigo.database.sql.SqlDataBaseManager) SqlConnection(io.vertigo.database.sql.connection.SqlConnection) ResourceManager(io.vertigo.core.resource.ResourceManager)

Aggregations

ResourceManager (io.vertigo.core.resource.ResourceManager)1 SqlDataBaseManager (io.vertigo.database.sql.SqlDataBaseManager)1 SqlConnection (io.vertigo.database.sql.connection.SqlConnection)1