What Is Data Hiding?

In this lesson, you will get familiar with a very important aspect of object-oriented programming called data hiding.

Introduction

In the previous chapter, you got familiar with the concepts of objects and classes.

In OOP, objects and classes are the basic entities. Objects are created using classes. One can observe that classes contain fields and objects are created to manipulate and access these fields. To make this object-oriented system more reliable and error-free, it is good practice to limit access to the class members.

In layman’s terms, data ...