arrow-validation / arrow.validation.refinedTypes.generic / NonEmpty / nonEmpty

nonEmpty

open fun A.nonEmpty(): Kind<F, A>

Commented method or class

import arrow.validation.refinedTypes.generic.validated.nonEmpty.nonEmpty

fun main(args: Array<String>) {
  //sampleStart
  val result = listOf(1, 2, 3).nonEmpty(emptyList())
 //sampleEnd

 println(result.isValid)
 }

open fun <B> A.nonEmpty(f: (A) -> B): Kind<F, B>

Do you like Arrow?

Arrow Org
<