ValixValidator

interface ValixValidator<T>

ValixValidator is a type-safe Kotlin validator interface. Implementations of this interface are generated at compile time by KSP to execute validations at runtime without reflection.

Parameters

T

The type of the target object being validated.

Functions

Link copied to clipboard
abstract fun validate(value: T, vararg groups: KClass<*>, failFast: Boolean = false): ValidationResult

Validates the target instance against configured constraints.

Link copied to clipboard
open suspend fun validateAsync(value: T, vararg groups: KClass<*>, failFast: Boolean = false): ValidationResult

Asynchronously validates the target instance against configured constraints.