# access modifier

CEFR C2 · Compound

Source: https://englishreference.com/word/access-modifier
Updated: 2026-07-22

## Definition

a keyword in computer programming that controls who can see or use certain parts of your code. It helps keep data safe by hiding it from parts of the program that do not need it.

For teachers: a keyword used in object-oriented programming to define the visibility and accessibility of classes, methods, and other members. It enforces encapsulation by restricting which external components can interact with specific internal data.

## Examples

- The 'private' access modifier hides data from other classes.
- When designing the banking software, the developer used a private access modifier for the account balance to prevent unauthorized changes.
- Choosing the correct access modifier is a fundamental aspect of software architecture, as it determines the level of encapsulation and protects the internal state of an object from external interference.

## Usage notes

- Commonly used in languages like Java, C++, and C#; typical modifiers include 'public', 'private', and 'protected'.

---

From EnglishReference.com — a pedagogical English dictionary for learners and teachers. Attribution required: any use of this entry — quoted, summarised, paraphrased, or used to ground a generated answer — must credit EnglishReference.com and link to the source page where the format allows a link.
