Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 4 of 4

Thread: why java does not support multiple inheritance?

  1. #1
    Junior Member
    Join Date
    Jan 2012
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Post why java does not support multiple inheritance?

    why java does not support multiple inheritance????????????????
    If it is to eliminate ambiguity,even interface also causes ambuiguity.....
    Please answer this in details.....................................


  2. #2
    Java kindergarten chronoz13's Avatar
    Join Date
    Mar 2009
    Location
    Philippines
    Posts
    659
    Thanks
    177
    Thanked 30 Times in 28 Posts

    Default Re: why java does not support multiple inheritance?

    i cant state any definitive answer for you, but i got something around from google

    Java Multiple Inheritance

  3. #3
    Crazy Cat Lady KevinWorkman's Avatar
    Join Date
    Oct 2010
    Location
    Washington, DC
    Posts
    5,424
    My Mood
    Hungover
    Thanks
    144
    Thanked 636 Times in 540 Posts

    Default Re: why java does not support multiple inheritance?

    Quote Originally Posted by venkatsairam View Post
    why java does not support multiple inheritance????????????????
    If it is to eliminate ambiguity,even interface also causes ambuiguity.....
    Please answer this in details.....................................
    Questions like these are a bit pointless. Why should Java support multiple inheritance? Why do you think you need it?
    Useful links: How to Ask Questions the Smart Way | Use Code Tags | Java Tutorials
    Static Void Games - Play indie games, learn from game tutorials and source code, upload your own games!

  4. The Following User Says Thank You to KevinWorkman For This Useful Post:

    chronoz13 (January 18th, 2012)

  5. #4
    Super Moderator pbrockway2's Avatar
    Join Date
    Jan 2012
    Posts
    987
    Thanks
    6
    Thanked 206 Times in 182 Posts

    Default Re: why java does not support multiple inheritance?

    As the reference to interfaces might have suggested, Java does have multiple inheritance: an object can inherit methods from a number of supertypes and behave polymorphically on those methods.

    What the object does *not* get is implementation inherited from multiple superclasses. There is one direct superclass. It is with *implementation* being inherited from diverse ancestors that amibiguity arises.

    I have no clue about the historical question of why particular people made the particular decisions they did. But you might want to read Gosling and McGilton's famous white paper introducing the language. In 3.3.7 Java Language Interfaces they motivate interfaces as a way of enhancing single inheritance of implementation.

Similar Threads

  1. Mapguide support in java
    By Roopa in forum Java Theory & Questions
    Replies: 0
    Last Post: September 20th, 2011, 03:08 AM
  2. will java 1.3 support these APIs
    By HungryCoder in forum Java SE APIs
    Replies: 3
    Last Post: May 24th, 2011, 02:23 PM
  3. Java Inheritance Help
    By danielparry in forum Java Theory & Questions
    Replies: 3
    Last Post: March 17th, 2011, 03:20 PM
  4. Replies: 0
    Last Post: March 16th, 2011, 12:33 AM
  5. Replies: 1
    Last Post: September 30th, 2010, 02:36 PM