This week's book giveaway is in the Agile forum.
We're giving away four copies of The Software Craftsman and have Sandro Mancuso on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes Multiple inheritance. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Software Craftsman this week in the Agile forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Multiple inheritance." Watch "Multiple inheritance." New topic
Author

Multiple inheritance.

T sandya
Ranch Hand

Joined: Aug 03, 2006
Posts: 64
I have two classes, Class A and Class B.
Class A is implicitly extending the Class Object.
Now if Class B extending the Class A, Class B also extending the Object Class, so it is violating the multiple
inheritance concept in java right?
how it is possible.?
Jesper de Jong
Java Cowboy
Saloon Keeper

Joined: Aug 16, 2005
Posts: 14669
    
  25

No, multiple inheritance is extending two classes at the same level. In your example, the base classes are not at the same level.

Please do a search for "multiple inheritance" in the forums here; this topic is discussed regularly here, and your question has been asked often. If you do a search you will find a list of answers very quickly.


Java Beginners FAQ - JavaRanch SCJP FAQ - The Java Tutorial - Java SE 8 API documentation
 
Have you tried LearnNowOnline? http://www.learnnowonline.com/
 
subject: Multiple inheritance.