Passing mandatory data to super classes in Kotlin
问题 I've got an issue creating entities in Kotlin. In particular, it's about passing data to a super class. Find an example below. I've got an abstract super class called Trackable that classes can extend. It has a user property that stores who has created that particular object. abstract class Trackable( var createdBy: User ) : Persistable() An class called Contract would now implement the Trackable super class with a compile-time error for the time being: @Entity data class Contract( var