As both encapsulation and abstraction relate to information hiding, can I understand encapsulation as a subset of abstraction?
As both encapsulation and abstraction relate to information hiding, can I understand encapsulation as
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Encapsulation is just one way of achieving abstraction.
‘abstraction‘ is a concept, it is the idea of defining or understanding a particular ‘thing’ (whatever that may be) through its essential properties or behaviors.
‘encapsulation‘ is a computer science technique used to produce classes which allow dealing with concrete objects in a fashion that reduces them to their abstract components.
In the domain of computer science, other techniques such as the use of graphs and other data structures are another way of providing abstraction for various underlying ‘things’, which even though they may not look anything like the graphs (or the matrices or other structures) have some of their essential characteristics embodied in these structures.
In other domains, abstraction can be achieved in very diverse fashion, such as the never ending classification process at work in the human brains, which creates and maintains “prototypes” (high level invariant representations) representing everyday concepts.