How a class can implement an interface?

Answers were Sorted based on User's Feedback



How a class can implement an interface?..

Answer / debapriya patra

By using the "implements" clause

Is This Answer Correct ?    7 Yes 1 No

How a class can implement an interface?..

Answer / ravikiran

with implements keyword

Is This Answer Correct ?    4 Yes 0 No

How a class can implement an interface?..

Answer / asrinivas rao

In java a class can implement interface using "implemnts"
keyword.the methods defined in the interface need to be
implemented in the class which implments the respective
interface,otherwise the class becomes has an Abstract class.

Is This Answer Correct ?    3 Yes 0 No

How a class can implement an interface?..

Answer / ranganathkini

A class can implement an interface by using the "implements"
clause followed by a list of interface names that it
implements. Then the class needs to implement the
interface's methods within its class body.

Is This Answer Correct ?    2 Yes 1 No

How a class can implement an interface?..

Answer / mayuri wankhade

without using implements clause it is also possible to use
interface by creating object of an interface in the class
containing main method like :

nameOfInterface Obj = new nameOfInterface()
{
implement a method declared in an interface
};
Obj.MethodName();

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Core Java Interview Questions

can we overload main method?

8 Answers   TCS,


What is native method in java?

0 Answers  


What methodology can be employed to locate substrings inside a string?

0 Answers  


Why we can not force Garbage Collection?

7 Answers  


Difference between character constant and string constant in java ?

0 Answers  






What is clipping?

2 Answers  


In Inheritence concept, i have a static method in super class and i am inheriting that class to one sub class.in that case the static method is inherited to sub class or not????

12 Answers   Accenture,


What’s the difference between the methods sleep() and wait()?

0 Answers  


Hai all I want to print given array in reverse order Ex: int a[]={1,2,3,4,5};display this array in reverse order.

4 Answers  


What is namespace in java?

0 Answers  


String class is defined under which package in java?

0 Answers  


Why java does not supports multiple inheritance?

3 Answers   TCS, VSoft,


Categories