RE: what is the difference between abstract class & Fi...
An abstact clas is a class which must be sub-classed and a final class is a class which cant be sub-classed. That means to get the functinaity of an abstract class we must sub class it and use the sub-class but on the other hand a final class must be used as it is without any alteration.......Hope this satisfies all...
RE: what is the difference between abstract class & Fi...
An abstract class in contrast provides more structure. It usually defines some default implementations and provides some tools useful for a full implementation. The catch is code using it must use your class as the base. That may be highly inconvenient if the other programmers wanting to use your package have already developed their own class hierarchy independently. In Java a class can inherit from only one base class
RE: what is the difference between abstract class & Fi...
Abstract class -> it is not must to override all methods in abstract class. Abstract class may contain abstract methods and non abstract methods.. in this case abstract methods should be overriden and non abstract methods are need not to be overriden
Abstract class can be inherited
Final class -> overriden is not possible this class cannot be inherited..
RE: what is the difference between abstract class & Final class
An abstact clas is a class which must be sub-classed and a final class is a class which cant be sub-classed. That means to get the functinaity of an abstract class we must sub class it and use the sub-class but on the other hand a final class must be used as it is without any alteratio
RE: what is the difference between abstract class & Final class
Abstract Class -> In this class we can create 'n' number of methods which can be prefixed by Abstract are abstract methods and which are not prefixed are non-abstract methods. There we can do declaration of the method and partial implementation. We can use all the methods declared in this class in sub classes or we can skip the methods which we dont want. Abstract Classes doesn't create an object. We can Extend this class
Final Class -> The Methods declared in this class wont change till the end of the program. We can't extend the Final Class.
RE: what is the difference between abstract class & Final class
object creation -- objects can't be created for abstract class but for a final class we can create objects inheritence -- final class can't be subclassed but abstract class can be subclassed