| Start | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Basics: the 'open' keyword In Kotlin, classes are final by default which means they cannot be inherited from. To allow inheritance on a class, use the **Note:** abstract classes, sealed classes and interfaces will be `open` by default. |
||||||||||||
Inheriting fields from a class Defining the base class:Defining the derived class:Using the subclass: |
||||||||||||
Inheriting methods from a class Defining the base class:Defining the derived class:The Ninja has access to all of the methods in Person |
||||||||||||
Overriding properties and methods Overriding properties (both read-only and mutable):Overriding methods:Syntax
Parameters
|
Read Article
https://develop.horje.com/learn/1434/reference