map

fun <T, R> SparseArray<T>.map(modifier: (T) -> R): SparseArray<R>

Maps the SparseArray to a new SparseArray using the provided modifier.

Return

a new SparseArray with the modified elements.

Parameters

modifier

the modifier to apply to each element.