function Constraint::checkFormat
Checks format of an element
Parameters
mixed $value:
mixed $schema:
JsonPointer|null $path:
mixed $i:
2 calls to Constraint::checkFormat()
- NumberConstraint::check in vendor/
justinrainbow/ json-schema/ src/ JsonSchema/ Constraints/ NumberConstraint.php - invokes the validation of an element
- StringConstraint::check in vendor/
justinrainbow/ json-schema/ src/ JsonSchema/ Constraints/ StringConstraint.php - invokes the validation of an element
File
-
vendor/
justinrainbow/ json-schema/ src/ JsonSchema/ Constraints/ Constraint.php, line 184
Class
- Constraint
- The Base Constraints, all Validators should extend this class
Namespace
JsonSchema\ConstraintsCode
protected function checkFormat($value, $schema = null, ?JsonPointer $path = null, $i = null) {
$validator = $this->factory
->createInstanceFor('format');
$validator->check($value, $schema, $path, $i);
$this->addErrors($validator->getErrors());
}