1 | <?php |
||
11 | class ImportRecord extends Job |
||
12 | { |
||
13 | protected $record; |
||
14 | protected $collection; |
||
15 | |||
16 | /** |
||
17 | * ImportRecord constructor. |
||
18 | * @param Collection $collection |
||
19 | * @param QuiteSimpleXMLElement $record |
||
20 | */ |
||
21 | public function __construct(Collection $collection, QuiteSimpleXMLElement $record) |
||
26 | |||
27 | /** |
||
28 | * @param Marc21Importer $importer |
||
29 | */ |
||
30 | public function handle(DocumentsIndex $docIndex, Marc21Importer $importer) |
||
35 | |||
36 | /** |
||
37 | * @param DocumentsIndex $docIndex |
||
38 | * @param int $docId |
||
39 | */ |
||
40 | public function imported($docIndex, $docId) |
||
51 | } |
It seems like the method you are trying to call exists only in some of the possible types.
Let’s take a look at an example:
Available Fixes
Add an additional type-check:
Only allow a single type to be passed if the variable comes from a parameter: