Define interface in java?



Define interface in java?..

Answer / Balram

In Java, an Interface is a reference type that contains abstract methods (methods without bodies) and constant variables. It provides a contract to which implementing classes must adhere. Interfaces allow multiple inheritance in Java by allowing a class to implement multiple interfaces. They are used for defining behavioral contracts, promoting loose coupling between objects, and enabling polymorphism.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Core Java Interview Questions

What are wrapped classes in java programming?

1 Answers  


What is map and hashmap in java?

1 Answers  


Can we assign null to double in java?

1 Answers  


What is java algorithm?

1 Answers  


can u handle an error if u write Thowable in the catch class lise try { some errorneous code }catch(Throwable e){ ...}

4 Answers  


Why is static used?

1 Answers  


What is the point of polymorphism java?

1 Answers  


Explain features of interfaces in java?

1 Answers  


What about interrupt() method of thread class ?

1 Answers  


How do I know if java is installed?

1 Answers  


explain the concept of virtual method invocation in polymorphism in detail?

1 Answers   TCS,


Explain Global variables in Packages?

4 Answers  


Categories