3
Reply

What is the use of abstract class ?

Panduranga Nadikuda

Panduranga Nadikuda

Sep 24, 2016
363
0

    Incomplete class

    Mukesh Kumar
    September 05, 2017
    0

    Abstract classes are used in scenarios, when there is a need of Multi level inheritances of classes, and they should also implement a Interface. Eg: suppose you have a interface named InterfaceTest with 4 properties and class A has implemented this interface. Now the situation arises that i have to inherit a Class B from Class A. Now when Class B tries to inherit from Class A, Class B will be forced to implement the interface properties which are already implemented by the Class A. So this will continue unless you , place a Abstract Class between Interface and Class A. In this scenario the abstract class will implement the interface , and the class A will inherit from the abstract class.But now the difference, is the Class A , need not implement any of the interface properties.

    satya panda
    June 05, 2017
    0

    1.If you are designing large functional units, use an abstract class. 2.If you want to provide common, implemented functionality among all implementations of your component, use an abstract class. 3.Abstract classes allow you to partially implement your class

    sanjay kumar
    March 23, 2017
    0