tarek
12/12/2018, 10:09 PMval myFunc: A.() -> Unit = { // this: A
customField = "value"
}
val otherFunc: A.() -> Unit = { // this: A
otherField = "other"
}
I want to have a function that is the combination of both above
I don't know how to write this.sandi
12/12/2018, 10:18 PMthis
and call one after the other, or .apply
both:
A().apply {
myFunc()
otherFunc()
}
gildor
12/13/2018, 2:42 AMfun A.combined() {
myFunc()
otherFunc()
}
A().combined()