Kotlin Programming Cookbook
上QQ阅读APP看书,第一时间看更新

Using when with custom objects

In Kotlin, when is already so powerful but did you know you can also use custom objects in when? Amazing, right? Let's go about implementing it.