how to inherit Constructor from super class to sub class
How to inherit the constructor from a super class to a sub class? Constructors are not inherited, you must create a new, identically prototyped constructor in the subclass that maps to its matching constructor in the superclass. Here is an example of how this works: class Foo { Foo(String str) { } } class Bar extends Foo { Bar(String str) { // Here I am explicitly calling the superclass // constructor - since constructors are not inherited // you must chain them like this. super(str); } } Superclass constructor CAN'T be inherited in extended class. Although it can be invoked in extended class