![JAR search and dependency download from the Maven repository](/logo.png)
ru.hnau.jutils.producer.extensions.ProducerExtensionsString.kt Maven / Gradle / Ivy
package ru.hnau.jutils.producer.extensions
import ru.hnau.jutils.producer.Producer
import java.util.*
fun Producer.callIfEmpty() = callIf { it.isEmpty() }
fun Producer.callIfBlank() = callIf { it.isBlank() }
fun Producer.callIfNullOrEmpty() = callIf { it.isNullOrEmpty() }
fun Producer.callIfNullOrBlank() = callIf { it.isNullOrBlank() }
fun Producer.filterNotEmpty() = filter { it.isNotEmpty() }
fun Producer.filterNotBlank() = filter { it.isNotBlank() }
fun Producer.toUpperCase() = map { it.toUpperCase() }
fun Producer.toLowerCase() = map { it.toLowerCase() }
fun Producer.toUpperCase(locale: Locale) = map { it.toUpperCase(locale) }
fun Producer.toLowerCase(locale: Locale) = map { it.toLowerCase(locale) }
fun Producer.trim() = map { it.trim() }
fun Producer.trimStart() = map { it.trimStart() }
fun Producer.trimEnd() = map { it.trimEnd() }
© 2015 - 2025 Weber Informatics LLC | Privacy Policy