isRight
Returns false
if Left or Both, or returns the result of the application of the given predicate to the Right value.
Example:
import arrow.core.Ior
fun main() {
Ior.Right(12).isRight { it 10 } // Result: false
Ior.Both(12, 7).isRight { it 10 } // Result: false
val left: Ior<Int, Int> = Ior.Left(12)
left.isRight { it 10 } // Result: true
}
Content copied to clipboard