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...

when to use abstract class and when to use interface?

Answer Posted / jc

If you want give different implementation(behaviour) to
methods which are available in the interface go for
interface.
If you want give different implementation to particular
methods(that is only some methods which are not similar to
subclass)go for abstract class.

Is This Answer Correct ?    0 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can an interface be defined inside a class?

1054


What is private static class in java?

1013


What is the maximum size of list in java?

960


State differences between C and Java?

1202


What do bitwise operators do?

1006


Is sizeof a preprocessor?

986


What is the use of keywords in java?

978


What is stream api in java8?

1165


Which collection is best for sorting in java?

1124


What is the use of join method?

1026


What is string value?

1156


What is the super void?

897


What is floor in java?

1034


Can the interface be final?

1005


What is the differences between heap and stack memory in java? Explain

978