Here you can find the source of getConnection(final String url)
public static Connection getConnection(final String url)
//package com.java2s; //License from project: Open Source License import java.sql.Connection; import java.sql.DriverManager; import java.sql.SQLException; import java.util.Properties; public class Main { public static Connection getConnection(final String url) { try {//from w ww . jav a 2 s . c o m return DriverManager.getConnection(url); } catch (SQLException e) { return null; } } public static Connection getConnection(final String url, final String user, final String password) { try { return DriverManager.getConnection(url, user, password); } catch (SQLException e) { return null; } } public static Connection getConnection(final String url, final Properties info) { try { return DriverManager.getConnection(url, info); } catch (SQLException e) { return null; } } }