Validator

caliban.validation.Validator
object Validator

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Self type
Validator.type

Members list

Type members

Types

A QueryValidation is a pure program that can access a Context, fail with a ValidationError or succeed with Unit.

A QueryValidation is a pure program that can access a Context, fail with a ValidationError or succeed with Unit.

Attributes

Value members

Concrete methods

def failValidation(msg: String, explanatoryText: String): Either[ValidationError, Nothing]
def prepare(document: Document, rootType: RootType, operationName: Option[String], variables: Map[String, InputValue], skipValidation: Boolean, validations: List[QueryValidation]): Either[ValidationError, ExecutionRequest]

Prepare the request for execution. Fails with a caliban.CalibanError.ValidationError otherwise.

Prepare the request for execution. Fails with a caliban.CalibanError.ValidationError otherwise.

Attributes

def validate(document: Document, rootType: RootType)(implicit trace: Trace): IO[ValidationError, Unit]

Verifies that the given document is valid for this type. Fails with a caliban.CalibanError.ValidationError otherwise.

Verifies that the given document is valid for this type. Fails with a caliban.CalibanError.ValidationError otherwise.

Attributes

def validateAll(document: Document, rootType: RootType): Either[ValidationError, Unit]

Verifies that the given document is valid for this type for all available validations. Fails with a caliban.CalibanError.ValidationError otherwise.

Verifies that the given document is valid for this type for all available validations. Fails with a caliban.CalibanError.ValidationError otherwise.

Attributes

Concrete fields