Results 1 to 2 of 2
  1. #1
    preety is offline Member
    Join Date
    Apr 2013
    Posts
    2
    Rep Power
    0

    Default constructor inheritence

    why constructor not inherited in java .plz explain in detail

  2. #2
    JosAH's Avatar
    JosAH is offline Moderator
    Join Date
    Sep 2008
    Location
    Voorschoten, the Netherlands
    Posts
    13,520
    Blog Entries
    7
    Rep Power
    20

    Default Re: constructor inheritence

    Quote Originally Posted by preety View Post
    why constructor not inherited in java .plz explain in detail
    What is there to inherit? If you do, say, "new X()" the constructor for class X has to be invoked, not one of X's subclasses; what subclass? If a constructor of a superclass of class X is to be invoked only that superclass part of the new X object will be initialized.

    kind regards,

    Jos
    cenosillicaphobia: the fear for an empty beer glass

Similar Threads

  1. Basic inheritence question
    By jubbiejub in forum New To Java
    Replies: 8
    Last Post: 03-17-2012, 04:35 AM
  2. Inheritence
    By UJJAL DHAR in forum New To Java
    Replies: 0
    Last Post: 12-04-2010, 09:11 AM
  3. inheritence questions
    By mac in forum New To Java
    Replies: 1
    Last Post: 04-05-2010, 10:54 PM
  4. Getting around inheritence
    By nick2price in forum New To Java
    Replies: 3
    Last Post: 01-18-2009, 06:48 AM
  5. [SOLVED] Problem with code - inheritence
    By yalla in forum New To Java
    Replies: 1
    Last Post: 03-30-2008, 06:11 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •