1 | <?php |
||
11 | class ReaderEntityFactory |
||
12 | { |
||
13 | /** |
||
14 | * This creates an instance of the appropriate reader, given the type of the file to be read |
||
15 | * |
||
16 | * @param string $readerType Type of the reader to instantiate |
||
17 | * @throws \Box\Spout\Common\Exception\UnsupportedTypeException |
||
18 | * @return ReaderInterface |
||
19 | */ |
||
20 | 79 | public static function createReader($readerType) |
|
24 | |||
25 | /** |
||
26 | * Creates a reader by file extension |
||
27 | * |
||
28 | * @param string The path to the spreadsheet file. Supported extensions are .csv,.ods and .xlsx |
||
29 | * @throws \Box\Spout\Common\Exception\IOException |
||
30 | * @throws \Box\Spout\Common\Exception\UnsupportedTypeException |
||
31 | * @return ReaderInterface |
||
32 | */ |
||
33 | public static function createReaderFromFile(string $path) |
||
37 | } |
||
38 |