Q

Why use abstraction?

If we use if-else with polymorphic behavior, then why do we use abstraction?

Abstraction allows the developer to separate objects so that they can work on different levels of detail more easily. For instance, if you are defining an object-oriented application to model a zoo, you can define a base class "animal", then derive "reptile", "mammal", "bird", and "fish" from it. The "animal" class implements the attributes and actions of all animals. Each of the derived classes refines those attributes and actions to a finer level of detail.

For More Information


This was last published in December 2002

Dig Deeper on Oracle DBA jobs, training and certification

PRO+

Content

Find more PRO+ content and other member only offers, here.

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

Start the conversation

Send me notifications when other members comment.

By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Please create a username to comment.

-ADS BY GOOGLE

SearchDataManagement

SearchBusinessAnalytics

SearchSAP

SearchSQLServer

TheServerSide

SearchDataCenter

SearchContentManagement

SearchFinancialApplications

Close