Encapsulation and Inheritance - ICSE Class 10 Computer Applications Notes, Diagrams and Solved Questions
Encapsulation and data hiding, access modifiers and their visibility, the scope of variables, base and derived classes with extends, the types of inheritance, and board-style inheritance programs.
In this chapter
Encapsulation: private data with getter and setter methods
private, default, protected and public, with a visibility explorer
Scope of class, instance, argument and local variables
Inheritance with extends: base and derived classes and why we use them
Single, multilevel and hierarchical inheritance (and why not multiple)
What is inherited, and the order constructors run in, step by step
Designing class hierarchies and writing exam programs with inheritance