descendantsWith

fun View?.descendantsWith(out: ArrayList<View> = arrayListOf(), check: (View) -> Boolean): List<View>

Returns a list of descendants including this that matches the check method. Allows to provide an out array to reduce allocations.