GoConqr hat ein neues Design! Sag uns, wie es dir gefällt.

Mindmap

Inheritance

Bryce Gatt Englisch

Inhalt der Mindmap

Inheritance

  1. Extends: Extends a class when placed in class declaration.

  2. "Is-a" relationship: Connects a subclass to a superclass.

  3. Subclass: Inherits all the public methods of it's superclass.

  4. Same Package: If a superclass and a subclass are in the same package, you can access the superclass's default methods and fiends, not just its public methods.

  5. Protected Methods: Cannot be accessed from outside unless by a subclass.

  6. Method Overriding: When you change the behavior of a method in the parent class.

  7. Super: Represents an instance of the direct superclass of the current object.

  8. Constructors:

    • Sub: Calls the single argument constructor of the parent class
    • Base
  9. Hidden Members: Hidden members or overridden methods in the superclass can be called by the super keyword.

  10. Type Casting:

    • Upcasting: When an object is casted to a parent class.
    • Downcasting: When an object is casted down a class in the inheritance heirarchy.
  11. Final: Prevents others from extending a class.

  12. "Instanceof": This keyword can be used to test if an object is of a specified type.

Informationen

Beschreibung
Mindmap am Inheritance, erstellt von Bryce Gatt am 21/11/2019.
Erstellt von
Bryce Gatt
Aufrufe
0
Bewertung

Feedback

Worum geht es?

Wie gefällt dir das neue Design?

Dein Eindruck