What are the advantages of Interface in OOP? Please give me an example to show that using Interface is better than one without using Interface.
Printable View
What are the advantages of Interface in OOP? Please give me an example to show that using Interface is better than one without using Interface.
That sounds exactly like a test question. Why don't you take your OOP textbook and look up the answer yourself?
An interface is used to specify a class: e.g. if your class implements the interface Runnable, it's considered as a threading classQuote:
Originally Posted by ychhuong