What is Java interface for?

An interface in Java is a blueprint of a class. A Java interface contains static constants and abstract methods. The interface in Java is a mechanism to achieve abstraction. There can be only abstract methods in the Java interface, not the method body. It is used to achieve abstraction and multiple inheritance in Java .10 Şub 2022

Sizin İçin Seçtik  What happens when you extend an abstract class?

Leave a Reply

Your email address will not be published. Required fields are marked *