interface ConstraintViolationListInterface implements Traversable, Countable, ArrayAccess

A list of constraint violations.

Methods

add(ConstraintViolationInterface $violation)

Adds a constraint violation to this list.

addAll(ConstraintViolationListInterface $otherList)

Merges an existing violation list into this list.

get(integer $offset)

Returns the violation at a given offset.

Boolean
has(integer $offset)

Returns whether the given offset exists.

set(integer $offset, ConstraintViolationInterface $violation)

Sets a violation at a given offset.

remove(integer $offset)

Removes a violation at a given offset.

Details

at line line 30
add(ConstraintViolationInterface $violation)

Adds a constraint violation to this list.

Parameters

ConstraintViolationInterface $violation The violation to add.

at line line 39
addAll(ConstraintViolationListInterface $otherList)

Merges an existing violation list into this list.

Parameters

ConstraintViolationListInterface $otherList The list to merge.

at line line 52
ConstraintViolationInterface get(integer $offset)

Returns the violation at a given offset.

Parameters

integer $offset The offset of the violation.

Return Value

ConstraintViolationInterface The violation.

Exceptions

OutOfBoundsException If the offset does not exist.

at line line 63
Boolean has(integer $offset)

Returns whether the given offset exists.

Parameters

integer $offset The violation offset.

Return Value

Boolean Whether the offset exists.

at line line 73
set(integer $offset, ConstraintViolationInterface $violation)

Sets a violation at a given offset.

Parameters

integer $offset The violation offset.
ConstraintViolationInterface $violation The violation.

at line line 82
remove(integer $offset)

Removes a violation at a given offset.

Parameters

integer $offset The offset to remove.