Logo 
Search:

Java Answers

Ask Question   UnAnswered
Home » Forum » Java       RSS Feeds
  Question Asked By: Clifton Flores   on Apr 29 In Java Category.

  
Question Answered By: Sophie Campbell   on Apr 29

class  cannot extend an interface they can only implement interfaces.
Interfaces on the other hand can extend from multiple  enterfaces but
interfaces cannot implement another interface.

Thus, in the code you have provided A must be a class and B must be an
interface and therefore B would have no constructor.

IMHO the original question  should be answered with another question:
what are you trying to do? Java doesn't have multiple inheritence but
in most cases it is not necessary since you can achieve similar results
using interfaces.

Share: 

 

This Question has 12 more answer(s). View Complete Question Thread

 
Didn't find what you were looking for? Find more on Multiple Inheritance Or get search suggestion and latest updates.


Tagged: