public function fromFile($file)
    {
        try {
            $data = file_get_contents($file);
            if ($data !== false) {
                return $this->parser->parse($data);
            }
            throw new \InvalidArgumentException("file could not be loaded");
        } catch (\Exception $e) {
            throw new \InvalidArgumentException("file could not be loaded (" . $e->getMessage() . ")");
        }
    }