File size: 657 Bytes
d2897cd
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
<?php

namespace Mautic\FormBundle\Exception;

class ValidationException extends \Exception
{
    /**
     * @var mixed[]
     */
    private array $violations = [];

    public function __construct($message = 'Validation failed', $code = 0, \Exception $previous = null)
    {
        parent::__construct($message, $code, $previous);
    }

    /**
     * @return mixed[]
     */
    public function getViolations(): array
    {
        return $this->violations;
    }

    /**
     * @param mixed[] $violations
     */
    public function setViolations(array $violations): self
    {
        $this->violations = $violations;

        return $this;
    }
}