_parentWriter = $pWriter; } /** * Get parent IWriter object * * @return \PhpOffice\PhpWord\Writer\IWriter * @throws \PhpOffice\PhpWord\Exceptions\Exception */ public function getParentWriter() { if (!is_null($this->_parentWriter)) { return $this->_parentWriter; } else { throw new Exception("No parent IWriter assigned."); } } }