Have you ever written any JDBC code? You "coded to an interface" then. The java.sql package defines interfaces (Connection, Statement etc) that you write your code against, and at runtime you load a specific JDBC driver which provides an actual implementation for those interfaces. But notice that you don't need to know you're using a particular driver when you're actually writing the code. That is "programming to an interface" in a nutshell: it allows you to not worry about the implementation details until later
>>>Have you ever written any JDBC code?
>Yes, I have. Thank you for this very clear and concise explanation.
And sometimes you can tell when people are uncomfortable with this.
They ask questions like: where are the implementations of Connection, Statement,
etc... What are the concrete classes? You have to tell them to stop worrying
and learn to love the abstraction...