java - Does superclass constructor exist (but not inherited) in subclass? -


we able invoke super() subclass constructor. since subclass is-a superclass , , there 1 object created ( new subclass()) imply superclass constructor exists, although cannot inherited, in subclass?

constructors not inherited. superclass constructor 'exists' in way call subclass unless it's marked private.

and i.k. has mentioned class have default constructor:

if class contains no constructor declarations, default constructor no formal parameters , no throws clause implicitly declared.


Comments

Popular posts from this blog

angularjs - Showing an empty as first option in select tag -

qt - Change color of QGraphicsView rubber band -

php - Cloud9 cloud IDE and CakePHP -