This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
I created an abstract class that uses a constructor to provide data and a method that a subclass can inherit. My subclass is stating that the abstract class's constructor is not being inherited. Here is my code. Parent class
Actually constructors are never inherited. If class Loan has a constructor with a set of parameters, and you need a constructor in PersonalLoan with the same set of parameters, you must implement it all over (and call super(...)); it isn't there "magically" like inherited methods are.
The thing with constructors is, they always call super() as the first line unless you specify another super() constructor to call or a call to this(...).