This week's giveaways are in the MongoDB and Jobs Discussion forums. We're giving away four copies of Mongo DB Applied Patterns and 4 resume reviews from Five Year Itch and have the authors/reps on-line! See this thread and this one for details.
You can't instantiate an Interface. You can however instantiate a class that implements that Interface. You ask about java.sql.Connection, well Connecitons are provided by your JDBC driver, which is implemented by a database vendor. So when you call this method (remember, Java has methods, not functions):
What is returned is an instance of a vendor specific Conenction implementation.
Here is a simple example of the type of thing that is happening in the DriverManager:
OK, here the interface is a java.util.List, but the method returns an java.util.ArrayList() that implements List. In the getConnection(String) method of DriverManager there will be some logic to ask the driver for an instance of its class that implements java.util.Connection. What could be returned might be an OracleConnection, or a JDTSConnection or whatever.