Interface is a mechanism to achieve fully abstraction. It's look looks like as class but not a class. It solve is with a powerful construct called interface.
It can be used to fully abstraction, generic template and multiple inheritance in java. It a blueprint of a class.
Advantage of interface:-
- Without bothering about implementation; we can achieve the security of implementation.
- Multiple interface can't be allow, however by using interface you can achieve the same.
- Interface are mainly used to provide polymorphic behavior.
No comments:
Post a Comment