The protected modifier

In Kotlin, the protected modifier is available to classes and interfaces, but not for top-level declarations. Classes, interfaces, methods, and properties marked with protected will be visible within their enclosing class and to any available subclasses.