Brief It’s almost true that every encapsulation is an abstraction because they both hide something, however, they have their fair share of differences. Difference between Abstraction and Encapsulation While both are fundamental concepts related to OOP and they are technically inseparable, they still have their differences in many aspects. Differences in “ Definition” of Abstraction and Encapsulation – Abstraction is a fundamental OOP concept which emphasizes on all the essential aspects of an object by hiding the irrelevant details to increase efficiency and eliminate complexity. Encapsulation, on the other hand, is a data hiding mechanism which wraps the data and information in a capsule to restrict access from outside world. Differences in “Functionality” of Abstraction and Encapsulation – Abstraction is a data hiding mechanism which highlights only the essential features to make complex programs simpler, while encapsulation, on the other hand, is a me...
This blog consists of the content that has been experienced by me at different age or different stages of my life. If any complain about any post please contact me. I will remove as soon as possible.