All Downloads are FREE. Search and download functionalities are using the official Maven repository.

commonMain.fr.haan.bipak.Paging.kt Maven / Gradle / Ivy

There is a newer version: 0.9.2
Show newest version
package fr.haan.bipak

/**
* Returns a PagingData containing the results of applying the given transform function to each element in the original list.
 */
public fun  PagingData.map(transform: (I) -> O): PagingData {
    return PagingData(
        list = list.map { transform(it) },
        state = state,
        totalCount = totalCount,
    )
}

internal fun pagingDebugLog(str: String) {
    // Log.d("Paging", str)
    println(str)
}