public function ConstraintViolationList::set

Sets a violation at a given offset.

@api

Parameters

integer $offset The violation offset.:

ConstraintViolationInterface $violation The violation.:

Overrides ConstraintViolationListInterface::set

1 call to ConstraintViolationList::set()
ConstraintViolationList::offsetSet in drupal/core/vendor/symfony/validator/Symfony/Component/Validator/ConstraintViolationList.php

File

drupal/core/vendor/symfony/validator/Symfony/Component/Validator/ConstraintViolationList.php, line 95

Class

ConstraintViolationList
Default implementation of {@ConstraintViolationListInterface}.

Namespace

Symfony\Component\Validator

Code

public function set($offset, ConstraintViolationInterface $violation) {
  $this->violations[$offset] = $violation;
}