When all booleans are set to true and I run startProcess() then it should be true and I want to execute the onFinished() method. How do I do this?
private var completed: BooleanArray = booleanArrayOf(false, false, false, false)
fun startProcess() {
completed.all { it -> callback.onFinished() }
}
if (completed.all { it }) { callback.onFinished() }?