Data encapsulation refers to the encapsulation of a data structure and the implementation of the operations applicable to it. An encapsulated data structure has an interface with the operations that can be accessed from outside. All accesses to the stored data take place exclusively over the operations of this interface.
Encapsulated data structures are often created as instances ofabstract data types. In object-oriented programming, objects form the units of data encapsulation.