public function testGetSetTitle() { $object = new Resource(); $this->assertEquals('', $object->getTitle()); $this->assertInstanceOf('PhpOffice\\PhpProject\\Resource', $object->setTitle('AAA')); $this->assertEquals('AAA', $object->getTitle()); }
/** * * @param XMLWriter $oXML * @param \PhpOffice\PhpProject\Resource $oResource */ private function writeResource(XMLWriter $oXML, \PhpOffice\PhpProject\Resource $oResource) { $oXML->startElement('resource'); $oXML->writeAttribute('id', $oResource->getIndex()); $oXML->writeAttribute('name', $oResource->getTitle()); $oXML->writeAttribute('function', 'Default:0'); $oXML->writeAttribute('contacts', ''); $oXML->writeAttribute('phone', ''); $oXML->endElement(); }
/** * Record "Resource" * @param Resource $oResource */ private function writeRecord50(Resource $oResource) { $this->fileContent[] = '50;' . $oResource->getIndex() . ';' . $oResource->getTitle(); }