Block Memorization Flashcards
Constructor Rules: 1/5
The first statement of every constructor is a call to another constructor within the class using this(), or a call to a constructor in the direct parent class using super().
Constructor Rules: 2/5
The super() call may not be used after the first statement of the constructor.
Constructor Rules: 3/5
If no super() call is declared in a constructor, Java will insert a no-argument super() as the first statement of the constructor.
Constructor Rules: 4/5
If the parent lacks a no argument constructor and the child doesn’t define any constructors, the compiler will through an error as it tries to insert a default no-argument super() constructor in the child class.
Constructor Rules: 5/5
If the parent doesn’t have a no0argument constructor, the compiler requires an explicit call to a parent constructor in each child constructor.