Semua buku

Profesional

Aplikasi Tentang Pelatih Masuk Mulai membaca

Computer Science · Glosarium

Apa itu Base class, derived class, inheritance?

Dikenal juga sebagai: derived class · base class · inheritance

Definition 3.1 University Computer Science — Year 2 · Bab 3 — Inheritance and Polymorphism

A class D declared as class D : public B is a derived class of the base class B. Every D object contains a B object (its base part) followed by the members D declares, and D has every member function of B. This is inheritance. A D can be used wherever a B is expected: a D * converts to a B * and a D binds to a B &, both pointing at the base part.

Baca dalam konteks →