public void createDatabase(File databaseFile, File sqliteStatements) throws SQLException {
        
        databaseFile.delete();
        parseSqlite(sqliteStatements);
        Connection connection = null;
        Statement stmt = null;
        ResultSet rs = null;
        int result;
        try {
            String path = "jdbc:sqlite:" + databaseFile.getAbsolutePath();
            connection = DriverManager.getConnection(path);
            connection.setAutoCommit(false);

            for (String statement : this.statements) {
                stmt = connection.createStatement();
                result = stmt.executeUpdate(statement);
            }
            connection.commit();
        }
        catch (SQLException ex) {
            Logger.getLogger(DatabaseCreator.class.getName()).log(Level.SEVERE, null, ex);
            if (connection != null) connection.rollback();
        }
        finally {
            if (connection != null) connection.close();
            if (stmt != null) stmt.close();
            if (rs != null) rs.close();
        }
    }