java - Super constructor call -


in java, if class extends super class , default first line of constructor super(), fields of super class initialized, or constructor run?

also, if constructor in superclass calls method happens in both classes, run super class or sub class version?

in java, if class extends super class , default first line of constructor super(), fields of super class initialised? or constructor run?

the fields of superclass initialized prior superclass constructor body running.

see section 15.9.4 , section 12.5 of jls details.

also, if constructor in superclass calls method happens in both classes, run super class or sub class version?

assuming subclass method overrides superclass one, subclass implementation called. seen bad thing, means method can't rely on initialized subclass constructor.


Comments

Popular posts from this blog

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -

javascript - firefox memory leak -

Trying to import CSV file to a SQL Server database using asp.net and c# - can't find what I'm missing -