1 | <?php |
||
12 | class HasSyntaxCorrectCheckInterface implements CheckInterface |
||
13 | { |
||
14 | const ERROR_STATUS = 'PARSER_ERROR'; |
||
15 | |||
16 | /** @var Parser */ |
||
17 | private $parser; |
||
18 | |||
19 | /** @var string */ |
||
20 | private $lastError; |
||
21 | |||
22 | |||
23 | |||
24 | /** |
||
25 | * @param Parser $parser |
||
26 | */ |
||
27 | public function __construct(Parser $parser) |
||
31 | |||
32 | |||
33 | |||
34 | /** |
||
35 | * @param Candidate $candidate |
||
36 | * @return bool True / False based on the fact if check is met or not |
||
37 | */ |
||
38 | public function execute(Candidate $candidate) |
||
51 | |||
52 | /** |
||
53 | * @return string |
||
54 | */ |
||
55 | public function getLastErrorMessage() |
||
59 | |||
60 | |||
61 | /** |
||
62 | * @return string |
||
63 | */ |
||
64 | public function getErrorCode() |
||
68 | } |