Encapsulation (computer programming): Difference between revisions

Content deleted Content added
Line 12:
 
This mechanism is not unique to object-oriented programming. Implementations of [[abstract data types]], e.g. [[module (programming)|modules]] offer a similar form of encapsulation. This similarity stems from the fact that both notions rely on the same mathematical fundament of an [[existential type]].<ref>Pierce (2002), Section 24.2 "Data Abstraction with Existentials"</ref>
 
Simple explanation for Encapsulation is chocolate. The wrapper is class and the cream of the chocolate are functions and the essence of the chocolate are attributes and putting in to a single unit is called encapsulation
 
== As bundling mechanism ==