Here you can find the source of getConnection()
public static Connection getConnection() throws SQLException
//package com.java2s; //License from project: Open Source License import java.sql.Connection; import java.sql.DriverManager; import java.sql.SQLException; public class Main { public static Connection getConnection() throws SQLException { try {/*w ww. j a v a 2s .c om*/ Class.forName("org.sqlite.JDBC"); } catch (ClassNotFoundException e) { e.printStackTrace(); System.exit(-1); } Connection connection = DriverManager.getConnection("jdbc:sqlite:test.db", "", ""); connection.setAutoCommit(false); return connection; } }