function BaseConstraint::addErrors
10 calls to BaseConstraint::addErrors()
- Constraint::checkArray in vendor/
justinrainbow/ json-schema/ src/ JsonSchema/ Constraints/ Constraint.php - Validates an array
- Constraint::checkEnum in vendor/
justinrainbow/ json-schema/ src/ JsonSchema/ Constraints/ Constraint.php - Checks a enum element
- Constraint::checkFormat in vendor/
justinrainbow/ json-schema/ src/ JsonSchema/ Constraints/ Constraint.php - Checks format of an element
- Constraint::checkNumber in vendor/
justinrainbow/ json-schema/ src/ JsonSchema/ Constraints/ Constraint.php - Checks a number element
- Constraint::checkObject in vendor/
justinrainbow/ json-schema/ src/ JsonSchema/ Constraints/ Constraint.php - Validates an object
File
-
vendor/
justinrainbow/ json-schema/ src/ JsonSchema/ Constraints/ BaseConstraint.php, line 68
Class
- BaseConstraint
- A more basic constraint definition - used for the public interface to avoid exposing library internals.
Namespace
JsonSchema\ConstraintsCode
public function addErrors(array $errors) {
if ($errors) {
$this->errors = array_merge($this->errors, $errors);
$errorMask =& $this->errorMask;
array_walk($errors, function ($error) use (&$errorMask) {
if (isset($error['context'])) {
$errorMask |= $error['context'];
}
});
}
}