@shmVirus

Encapsulation

Hiding implementation details behind well-defined interfaces to reduce coupling.

Encapsulation is the discipline of exposing only what clients need. This chapter covers access modifiers, getters and setters, the difference between interface and implementation, and why encapsulation makes code easier to change safely.