GeekInterview.com
Series: Subject: Topic:
Question: 9 of 573

Adding Method in Java

Hi I have interface in that interface 3 methods are there , after some days client said that,i want to add one more method in that interface ,so how can add 4 method so that the implemented class did not affect, Thanks Kalins Naik
Asked by: kalins.naik | Member Since Aug-2012 | Asked on: Aug 15th, 2012

View all questions by kalins.naik

Showing Answers 1 - 2 of 2 Answers
Vaibhav

Answered On : Aug 20th, 2012

You can use inheritance for that... You can inherit new class from the Existing class and add the method in that.

  
Login to rate this answer.
akii

Answered On : Apr 30th, 2013

make a class abstract in this class you do not need to implement all methods of interface .

  
Login to rate this answer.

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

Related Open Questions

Ads

Connect

twitter fb Linkedin GPlus RSS

Ads

Interview Question

 Ask Interview Question?

 

Latest Questions

Interview & Career Tips

Get invaluable Interview and Career Tips delivered directly to your inbox. Get your news alert set up today, Once you confirm your Email subscription, you will be able to download Job Inteview Questions Ebook . Please contact me if you there is any issue with the download.