People Inc. Interview Question

Asked basic OOP principles specifically encapsulation and when would you use