The concept of OOP was born in an effort to manage the increasing complexity of software systems. The concept of data and procedures bundled in an object with controlled access to them (called encapsulation) allows better-organized data and procedures in layers, some of them hidden, others exposed to an access from outside. The accessibility control described in the previous sections was a significant part of it. Together with inheritance, interface (also called abstraction), and polymorphism, encapsulation became one of the central concepts of OOP.
There is often no clear-cut separation of one OOP concept from another. Interfaces help to hide (encapsulate) the implementation details too. Inheritance, with its ability to override and hide methods of the parent classes, adds a dynamic aspect to the accessibility. All these three concepts make it possible to add...