isPositiveOrZero

@JvmName(name = "shortIsPositiveOrZero")
fun Validatable<Short?>.isPositiveOrZero(): Constraint
@JvmName(name = "intIsPositiveOrZero")
fun Validatable<Int?>.isPositiveOrZero(): Constraint
@JvmName(name = "longIsPositiveOrZero")
fun Validatable<Long?>.isPositiveOrZero(): Constraint
@JvmName(name = "floatIsPositiveOrZero")
fun Validatable<Float?>.isPositiveOrZero(): Constraint
@JvmName(name = "doubleIsPositiveOrZero")
fun Validatable<Double?>.isPositiveOrZero(): Constraint


The validatable Duration must be positive or zero when this constraint is applied.

Code example:

val validate = Validator<Duration> { isPositiveOrZero() }
validate(1.seconds) // Success
validate(0.seconds) // Success
validate((-1).seconds) // Failure (message: Must be positive or equal to zero)
@JvmName(name = "durationIsPositiveOrZero")
fun Validatable<Duration?>.isPositiveOrZero(): Constraint
@JvmName(name = "periodIsPositiveOrZero")
fun Validatable<Period?>.isPositiveOrZero(): Constraint