ValidateOps

com.github.arturopala.validator.Validator$.ValidateOps
final implicit class ValidateOps[T](val thisValidate: T => Result)

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any

Members list

Value members

Concrete methods

def &[T1 <: T](otherValidate: () => T1): () => T1

Conjuction. Compose this check with another check and expect them both to pass.

Conjuction. Compose this check with another check and expect them both to pass.

Attributes

def *[U](otherValidate: () => U): () => (T, U)

Product. Compose this check with another check to construct tuple of checks.

Product. Compose this check with another check to construct tuple of checks.

Attributes

def ?(otherValidate: () => T): () => T

Chain two constraints so that if first is true than the second is evaluated.

Chain two constraints so that if first is true than the second is evaluated.

Attributes

def ?!(otherValidate: () => T): () => T

Chain two constraints so that if first is false than the second is evaluated.

Chain two constraints so that if first is false than the second is evaluated.

Attributes

def @:(errorPrefix: String): () => T

Adds prefix to the error messages.

Adds prefix to the error messages.

Attributes

def @@(errorPrefix: String): () => T

Adds prefix to the error messages.

Adds prefix to the error messages.

Attributes

def and[T1 <: T](otherValidate: () => T1): () => T1

Conjuction. Compose this check with another check and expect them both to pass.

Conjuction. Compose this check with another check and expect them both to pass.

Attributes

def andWhenValid(otherValidate: () => T): () => T

Chain two constraints so that if first is true than the second is evaluated.

Chain two constraints so that if first is true than the second is evaluated.

Attributes

def andwhenInvalid(otherValidate: () => T): () => T

Chain two constraints so that if first is false than the second is evaluated.

Chain two constraints so that if first is false than the second is evaluated.

Attributes

def debug: () => T

Prints entity and the result for debug purposes.

Prints entity and the result for debug purposes.

Attributes

def debugWith(show: T => String): () => T

Prints entity using supplied function and the result for debug purposes.

Prints entity using supplied function and the result for debug purposes.

Attributes

def or[T1 <: T](otherValidate: () => T1): () => T1

Disjunction. Compose this check with another check and expect at least one of them to pass.

Disjunction. Compose this check with another check and expect at least one of them to pass.

Attributes

def withErrorPrefix(errorPrefix: String): () => T

Adds prefix to the error messages.

Adds prefix to the error messages.

Attributes

def withErrorPrefixComputed(errorPrefix: T => String): () => T

Adds computed prefix to the error messages.

Adds computed prefix to the error messages.

Attributes

def |[T1 <: T](otherValidate: () => T1): () => T1

Disjunction. Compose this check with another check and expect at least one of them to pass.

Disjunction. Compose this check with another check and expect at least one of them to pass.

Attributes

Concrete fields

val thisValidate: T => Result