public function __construct($filename) { $this->fp = fopen($filename, "wb+"); if ($this->fp === false) { throw new Exception("Cannot initialise FilePrintConnector."); } }