Programming Tutorials

Comment on Tutorial - Abstract classes in Java By Kamini



Comment Added by : Anil Chalhotra

Comment Added at : 2013-02-16 08:04:03

Comment on Tutorial : Abstract classes in Java By Kamini
hi What is the meaning of this line ,
you cannot declare abstract constructors, or abstract static methods.
---------------------
in ur example u have taken a constructor

abstract class Figure {
double dim1;
double dim2;
Figure(double a, double b) {
dim1 = a;
dim2 = b;
}
// area is now an abstract method
abstract double area();
}
------------

can we take a constructor in abstract class


View Tutorial