¡GoConqr estrena diseño! Cuéntanos qué te parece.

Mapa mental

Inheritance

Katie Arnott Inglés

Contenido del mapa

Inheritance

  1. what makes the code accessible in any OOP language

  2. the process of extending a class

    • can create a new class that will have a "parent child" relationship with the original
      • child class can be extended too until you specifically declare it as final
    • use EXTENDS keyword, after the class name and before parent class
  3. special "is-a" relationship created when extending a class

    • then can assign instance of subclass to a reference variable of the parent type
  4. from within subclass, can access a superclass public methods but not private

  5. you can override a method by writing new method in subclass, except a final method

    • if you do not explicitly write a constructor for a subclass, the compiler will implicitly add a no argument constructor
    • can use super keyword to call a hidden method in addition to helping implicitly write constructors
  6. can cast instance of subclass to its parent class

Información

Descripción
Mapa Mental sobre Inheritance, creado por Katie Arnott el 21/11/2019.
Creado por
Katie Arnott
Visitas
0
Valoración

Escríbenos

¿Sobre qué es tu mensaje?

¿Qué te parece el nuevo diseño?

¿Te gusta?