add android tools

This commit is contained in:
2020-11-10 15:43:15 +06:00
parent 97dadf517a
commit 5ce71ee6f6
44 changed files with 862 additions and 31 deletions

View File

@@ -0,0 +1 @@
<manifest package="dev.inmo.micro_utils.common"/>

View File

@@ -0,0 +1,7 @@
package dev.inmo.micro_utils.common
@Suppress("UNCHECKED_CAST", "SimplifiableCall")
inline fun <T, R> Iterable<T>.mapNotNullA(transform: (T) -> R?): List<R> = map(transform).filter { it != null } as List<R>
@Suppress("UNCHECKED_CAST", "SimplifiableCall")
inline fun <T, R> Array<T>.mapNotNullA(mapper: (T) -> R?): List<R> = map(mapper).filter { it != null } as List<R>