isNotInstanceOf
The validatable value must not be an instance of type parameter R when this constraint is applied.
Code example:
val validate = Validator<Any> { isNotInstanceOf<String>() }
validate(123) // Success
validate("foo") // Failure (message: Must not be an instance of "kotlin.String")
Content copied to clipboard