// damn API. $doc->addPersonSubmiter() doesn't work for link models! // -> we should change this in 4.x $submitter = new Opus_Person(); $submitter->setFirstName('Donald')->setLastName('Duck')->setEmail('*****@*****.**')->setDateOfBirth('1920-03-13')->setPlaceOfBirth('Entenhausen'); $doc->addPersonSubmitter($submitter); $author = new Opus_Person(); $author->setFirstName('Daniel')->setLastName('Düsentrieb')->setAcademicTitle('Dr.-Ing.'); $doc->addPersonAuthor($author); $doc->setLanguage('deu'); $titleMain = $doc->addTitleMain(); $titleMain->setValue('Dokument zur empirischen Unterschung der OAI-Schnittstelle'); $titleMain->setLanguage('deu'); $titleMainEng = $doc->addTitleMain(); $titleMainEng->setValue('Document for empirical testing OAI interface'); $titleMainEng->setLanguage('eng'); $abstract = $doc->addTitleAbstract(); $abstract->setValue('Dokument, dass alle Daten enhält, um testen zu können, wie die OAI-Schnittstelle sie ausgibt.'); $abstract->setLanguage('deu'); $titleSub = $doc->addTitleSub(); $titleSub->setValue('Beispielhaft erleutert an OPUS 4.0.0'); $titleSub->setLanguage('deu'); $titleAdditional = $doc->addTitleAdditional(); $titleAdditional->setValue('OAI-Schnittstellen empirisch testen am Beispiel von OPUS 4.0'); $titleAdditional->setLanguage('deu'); $titleParent = $doc->addTitleParent(); $titleParent->setValue('Tester interface d\'OAI en OPUS 4.0'); $titleParent->setLanguage('fra'); $doc->setPageNumber('123'); $doc->setPageFirst('122'); $doc->setPageLast('124'); $doc->setVolume('4');
/** * * @param DOMNode $node * @param Opus_Document $doc */ private function handleAbstracts($node, $doc) { foreach ($node->childNodes as $childNode) { if ($childNode instanceof DOMElement) { $t = $doc->addTitleAbstract(); $t->setValue(trim($childNode->textContent)); $t->setLanguage(trim($childNode->getAttribute('language'))); } } }