object Validator extends ValidatorMagnoliaDerivation with ValidatorEnumMacro
Linear Supertypes
Ordering
- Alphabetic
- By Inheritance
Inherited
- Validator
- ValidatorEnumMacro
- ValidatorMagnoliaDerivation
- AnyRef
- Any
- Hide All
- Show All
Visibility
- Public
- All
Type Members
- case class All[T](validators: Seq[Validator[T]]) extends Validator[T] with scala.Product with Serializable
- case class Any[T](validators: Seq[Validator[T]]) extends Validator[T] with scala.Product with Serializable
- case class CollectionElements[E, C[_]](elementValidator: Validator[E], toIterable: (C[E]) ⇒ Iterable[E]) extends Single[C[E]] with scala.Product with Serializable
- case class Custom[T](doValidate: (T) ⇒ Boolean, message: String) extends Primitive[T] with scala.Product with Serializable
- type EncodeToRaw[T] = (T) ⇒ Option[scala.Any]
- case class Enum[T](possibleValues: List[T], encode: Option[EncodeToRaw[T]]) extends Primitive[T] with scala.Product with Serializable
- case class Mapped[TT, T](wrapped: Validator[T], g: (TT) ⇒ T) extends Single[TT] with scala.Product with Serializable
- case class Max[T](value: T, exclusive: Boolean)(implicit valueIsNumeric: Numeric[T]) extends Primitive[T] with scala.Product with Serializable
- case class MaxLength[T <: String](value: Int) extends Primitive[T] with scala.Product with Serializable
- case class MaxSize[T, C[_] <: Iterable[_]](value: Int) extends Primitive[C[T]] with scala.Product with Serializable
- case class Min[T](value: T, exclusive: Boolean)(implicit valueIsNumeric: Numeric[T]) extends Primitive[T] with scala.Product with Serializable
- case class MinLength[T <: String](value: Int) extends Primitive[T] with scala.Product with Serializable
- case class MinSize[T, C[_] <: Iterable[_]](value: Int) extends Primitive[C[T]] with scala.Product with Serializable
- case class OpenProduct[E](elementValidator: Validator[E]) extends Single[Map[String, E]] with scala.Product with Serializable
- case class Pattern[T <: String](value: String) extends Primitive[T] with scala.Product with Serializable
- sealed trait Primitive[T] extends Single[T]
- case class Product[T](fields: Map[String, ProductField[T]]) extends Single[T] with scala.Product with Serializable
- trait ProductField[T] extends AnyRef
- sealed trait Single[T] extends Validator[T]
-
type
Typeclass[T] = Validator[T]
- Definition Classes
- ValidatorMagnoliaDerivation
Value Members
-
final
def
!=(arg0: scala.Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: scala.Any): Boolean
- Definition Classes
- AnyRef → Any
- def all[T](v: Validator[T]*): Validator[T]
- def any[T](v: Validator[T]*): Validator[T]
- implicit def arrayElements[T](implicit arg0: Validator[T]): Validator[Array[T]]
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
def
combine[T](ctx: CaseClass[Validator, T]): Validator[T]
- Definition Classes
- ValidatorMagnoliaDerivation
- def custom[T](doValidate: (T) ⇒ Boolean, message: String): Primitive[T]
-
def
dispatch[T](ctx: SealedTrait[Validator, T]): Validator[T]
- Definition Classes
- ValidatorMagnoliaDerivation
- Annotations
- @silent( "never used" )
-
def
enum[T](possibleValues: List[T], encode: EncodeToRaw[T]): Enum[T]
- encode
Specify how values of this type can be encoded to a raw value, which will be used for documentation. This will be automatically inferred if the validator is directly added to a codec.
- def enum[T](possibleValues: List[T]): Enum[T]
-
macro
def
enum[T]: Enum[T]
Creates an enum validator where all subtypes of the sealed hierarchy
Tareobjects.Creates an enum validator where all subtypes of the sealed hierarchy
Tareobjects. This enumeration will only be used for documentation, as a value outside of the allowed values will not be decoded in the first place (the decoder has no other option than to fail). -
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: scala.Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
fallback[T]: Validator[T]
- Definition Classes
- ValidatorMagnoliaDerivation
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- implicit def iterableElements[T, C[X] <: Iterable[X]](implicit arg0: Validator[T]): Validator[C[T]]
- def max[T](value: T, exclusive: Boolean = false)(implicit arg0: Numeric[T]): Primitive[T]
- def maxLength[T <: String](value: Int): Primitive[T]
- def maxSize[T, C[_] <: Iterable[_]](value: Int): Primitive[C[T]]
- def min[T](value: T, exclusive: Boolean = false)(implicit arg0: Numeric[T]): Primitive[T]
- def minLength[T <: String](value: Int): Primitive[T]
- def minSize[T, C[_] <: Iterable[_]](value: Int): Primitive[C[T]]
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- implicit def openProduct[T](implicit arg0: Validator[T]): Validator[Map[String, T]]
- implicit def optionElement[T](implicit arg0: Validator[T]): Validator[Option[T]]
- def pass[T]: Validator[T]
- def pattern[T <: String](value: String): Primitive[T]
- def reject[T]: Validator[T]
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
implicit macro
def
validatorForCaseClass[T]: Validator[T]
- Definition Classes
- ValidatorMagnoliaDerivation
-
def
validatorForEnum[E](c: Context)(implicit arg0: scala.reflect.macros.blackbox.Context.WeakTypeTag[E]): scala.reflect.macros.blackbox.Context.Expr[Enum[E]]
- Definition Classes
- ValidatorEnumMacro
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()