zero_coding
08/26/2020, 7:23 PMclass NoInterestsFound : RuntimeException()
Casey Brooks
08/26/2020, 7:31 PMRuntimeException
is a class, it is being extended and requires the parentheses as it is effectively calling the superclass constructorTobias Berger
08/26/2020, 7:31 PMRuntimeException
is a class and you have to call its constructor. It's like calling super()
in the first line of a Java constructor, kotlin just forces you to do it explicitly.Tobias Berger
08/26/2020, 7:33 PMextends
and implements
in kotlin, I'd say it's also very useful as a differentiation between interfaces and superclasses (as @Casey Brooks said)zero_coding
08/26/2020, 7:48 PM