1 | <?php |
||
12 | class CandidateProcessor |
||
13 | { |
||
14 | /** @var Check[] */ |
||
15 | private $checks; |
||
16 | |||
17 | /** @var string */ |
||
18 | private $lastError; |
||
19 | |||
20 | /** @var string */ |
||
21 | private $lastErrorMessage; |
||
22 | |||
23 | |||
24 | |||
25 | public function __construct() |
||
29 | |||
30 | |||
31 | |||
32 | /** |
||
33 | * @param Check $check |
||
34 | */ |
||
35 | public function addCheck(Check $check) |
||
39 | |||
40 | |||
41 | |||
42 | /** |
||
43 | * @param Candidate $candidate |
||
44 | * @return bool |
||
45 | */ |
||
46 | public function isValid(Candidate $candidate) |
||
60 | |||
61 | |||
62 | |||
63 | /** |
||
64 | * @return string |
||
65 | */ |
||
66 | public function getLastError() |
||
70 | |||
71 | |||
72 | |||
73 | /** |
||
74 | * @return string |
||
75 | */ |
||
76 | public function getLastErrorMessage() |
||
80 | } |