How do you define an array of funs(functions) in Kotlin?
This is my assumption of how it would be done...
this.funs = arrayOf : Unit(
this::openCamera,
this::sendSMS,
this::makeCall
)
How would I invoke each array item as a function at runtime? Would simply specifying 'funs' in place of either openCamera(), sendSMS(), and MakeCall() in a forEach() loop work?
or.. is this the way that I would invoke each function:
val function = getFunction(funs)
function()