apply()
is another Kotlin scope function. Whatever you call apply()
on is
available to the lambda expression as this
.
apply()
tends to be used for complex initialization of objects.
You can learn more about this in:
Tags: