Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
Total | n/a |
0 / 0 |
n/a |
0 / 0 |
CRAP | n/a |
0 / 0 |
1 | <?php |
2 | |
3 | namespace FileImporter\Interfaces; |
4 | |
5 | use FileImporter\Data\SourceUrl; |
6 | |
7 | /** |
8 | * Interface used to decide if the intended title of a file is allowed based on the SourceUrl. |
9 | * This usually means making requests to the site hosting the SourceUrl to get data. |
10 | * |
11 | * @license GPL-2.0-or-later |
12 | * @author Addshore |
13 | */ |
14 | interface ImportTitleChecker { |
15 | |
16 | /** |
17 | * @param SourceUrl $sourceUrl |
18 | * @param string $intendedFileName File name without the File: prefix |
19 | * |
20 | * @return bool is the import allowed |
21 | */ |
22 | public function importAllowed( SourceUrl $sourceUrl, string $intendedFileName ): bool; |
23 | |
24 | } |