Package-level declarations

Functions

Link copied to clipboard
inline fun <T> Flow<T>.csv(appendHeader: Boolean = true, delimiter: String = ";"): Flow<String>

Converts a flow of objects into a flow of CSV strings, using reflection to automatically map object fields to CSV columns.

Link copied to clipboard
fun Flow<String>.parseCsv(delimiter: String = ";"): Flow<List<String>>

Parses the CSV data from a flow of strings and emits each row as a list of strings.

fun <T> Flow<String>.parseCsv(delimiter: String = ";", f: (List<String>) -> T): Flow<T>

Parses the CSV data from a flow of strings and emits each row as a custom object, converted using the provided function.

Link copied to clipboard
fun Flow<String>.parseCsvWithHeaders(delimiter: String = ";"): Flow<Map<String, String>>

Parses the CSV data with headers from a flow of strings and emits each row as a map where the keys are the headers and the values are the corresponding row values.

fun <T> Flow<String>.parseCsvWithHeaders(delimiter: String = ";", f: (Map<String, String>) -> T): Flow<T>

Parses the CSV data with headers from a flow of strings and emits each row as a custom object, converted using the provided function.

Link copied to clipboard
fun <T> Flow<T>.rawCsv(vararg headers: String, delimiter: String = ";", f: (T) -> List<String>): Flow<String>
fun <T> Flow<T>.rawCsv(headers: List<String>, delimiter: String = ";", f: (T) -> List<String>): Flow<String>

Converts a flow of objects into a flow of raw CSV strings, using a provided function to convert each object into a list of strings.