-
Junior Member
Re: abstraction Vs encapsulation
Encapsulation has two faces; data abstraction and information hiding. Data abstraction is a type seen from the outside. Information hiding is a type seen from the inside.
Sometime encapsulation is used to mean information hiding only but I think the definition I gave is better because if you encapsulate something you get both an inside and an outside right.
* Abstraction focuses on the outside view of an object (i.e. the interface)
* Encapsulation (information hiding ) prevents clients from seeing its inside view, where the behavior of the abstraction is implemented
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules