Abstract vs Interface

From CSSEMediaWiki
(Difference between revisions)
Jump to: navigation, search
Line 1: Line 1:
We all know that we should [[Program_to_the_interface_not_the_implementation | program to the interface not the implementation]]
+
We all know that we should [[Program_to_the_interface_not_the_implementation | program to the interface not the implementation]]. But what ''is'' an interface? and how do we know what kind of interface to use?
 +
 
 +
You might think the answer is simple, and many times it is, but there is a case where the line becomes hard to distinguish.
 +
 
 +
That case is known as Abstract vs Interface.

Revision as of 00:55, 3 August 2010

We all know that we should program to the interface not the implementation. But what is an interface? and how do we know what kind of interface to use?

You might think the answer is simple, and many times it is, but there is a case where the line becomes hard to distinguish.

That case is known as Abstract vs Interface.

Personal tools