Akeneo\Component\SpreadsheetParser\SpreadsheetLoader::open PHP Method

open() public method

Opens a spreadsheet
public open ( string $path, string | null $type = null ) : Akeneo\Component\SpreadsheetParser\SpreadsheetInterface
$path string
$type string | null
return Akeneo\Component\SpreadsheetParser\SpreadsheetInterface
    public function open($path, $type = null)
    {
        $type = $type ?: $this->getType($path);
        if (!isset($this->loaders[$type])) {
            throw new InvalidArgumentException(sprintf('No loader for type %s', $type));
        }
        return $this->loaders[$type]->open($path);
    }