You are here

public function ConstraintViolationList::addAll in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/validator/ConstraintViolationList.php \Symfony\Component\Validator\ConstraintViolationList::addAll()

Merges an existing violation list into this list.

Parameters

ConstraintViolationListInterface $otherList The list to merge.:

Overrides ConstraintViolationListInterface::addAll

File

vendor/symfony/validator/ConstraintViolationList.php, line 65

Class

ConstraintViolationList
Default implementation of {@ConstraintViolationListInterface}.

Namespace

Symfony\Component\Validator

Code

public function addAll(ConstraintViolationListInterface $otherList) {
  foreach ($otherList as $violation) {
    $this->violations[] = $violation;
  }
}