Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Can you have a constructor in abstract class?

Answer Posted / suresh

any class which extends with an object class should have a
constructor whether a class is abstract class or not.
if a abstract class is super class to some sub classes,
then the abstract class should extneds with oject class.
EX: abstract class A{
A{
super(); /// it ll give a call to super class
/// super() we can use only in
constructor
}

}
class B extends A{

}
means any class should extnd with super class.
because of this abstract classes are not 100% abstract.
interface is 100% abstract.

Is This Answer Correct ?    0 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is java lang string?

983


What are the advantages of java over cpp?

1071


What is stringbuffer in java?

1060


How many functional interfaces does java 8 have?

1028


What will happen to the exception object after exception handling?

996


How are the elements of a gridbaglayout organized?

1063


Can a class be declared as protected?

1013


What is the use of default method in interface in java?

1009


What is oop in java?

1059


What is the difference between import java.util.date and java .util?

1052


Explain try and catch keywords in java?

1205


What is incompatible types in java?

1039


What is an infinite loop?

1255


Which oo concept is achieved by using overloading and overriding?

1012


Are functions objects in java?

1074