当前位置: 首页>>代码示例>>PHP>>正文


PHP Opus_Document::addIdentifierOpus3方法代码示例

本文整理汇总了PHP中Opus_Document::addIdentifierOpus3方法的典型用法代码示例。如果您正苦于以下问题:PHP Opus_Document::addIdentifierOpus3方法的具体用法?PHP Opus_Document::addIdentifierOpus3怎么用?PHP Opus_Document::addIdentifierOpus3使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Opus_Document的用法示例。


在下文中一共展示了Opus_Document::addIdentifierOpus3方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: testMapopus3Action

 /**
  * @deprecated since OPUS 3.0.2, the function under test is marked as deprecated
  * and will be removed in future releases
  */
 public function testMapopus3Action()
 {
     $opus3_id = 'foobar-' . rand();
     $this->_document->addIdentifierOpus3()->setValue($opus3_id);
     $doc_id = $this->_document->store();
     $this->dispatch('/frontdoor/index/mapopus3/oldId/' . $opus3_id);
     $this->assertResponseCode(302);
     $this->assertModule('frontdoor');
     $this->assertController('index');
     $this->assertAction('mapopus3');
     $response = $this->getResponse();
     $headers = $response->getHeaders();
     $this->assertEquals('Location', $headers[0]['name']);
     $this->assertStringEndsWith('/rewrite/index/id/type/opus3-id/value/' . $opus3_id, $headers[0]['value']);
     $this->checkForBadStringsInHtml($response->getBody());
 }
开发者ID:belapp,项目名称:opus4-application,代码行数:20,代码来源:IndexControllerTest.php

示例2: randString

    $instituteCollection = $instituteCollections[0];
} else {
    $rootCollection = $institutesRole->getRootCollection();
    if (is_null($rootCollection) === true) {
        $rootCollection = $institutesRole->addRootCollection();
        $rootCollection->setVisible(1)->store();
        $institutesRole->store();
    }
    $instituteCollection = $rootCollection->addLastChild();
    $instituteCollection->setVisible(1)->setName(randString($counter++))->store();
}
$doc->addCollection($instituteCollection);
//
// Identifiers
//
$oldOpusId = $doc->addIdentifierOpus3();
$oldOpusId->setValue(randString($counter++));
// empty URN will be automaticaly replace by new URN.
$urn = $doc->addIdentifierUrn();
$urn->setValue('urn:nbn:de:kobv:nn-opus-173:' . randString($counter++));
$isbn = $doc->addIdentifierIsbn();
$isbn->setValue('978-3-86680-192-9');
$issn = $doc->addIdentifierIssn();
$issn->setValue('1234-5678');
$doc->addIdentifierOpac()->setValue(randString($counter++));
//
// DnbInstitutes
//
$dnbInstitute = new Opus_DnbInstitute();
$dnbInstitute->setName(randString($counter++) . rand())->setAddress(randString($counter++))->setCity(randString($counter++))->setPhone(randString($counter++))->setDnbContactId(randString($counter++))->setIsGrantor(1)->store();
$doc->setThesisGrantor($dnbInstitute);
开发者ID:belapp,项目名称:opus4-application,代码行数:31,代码来源:opus-create-xss-document.php

示例3:

    if (is_null($rootCollection) === true) {
        $rootCollection = $institutesRole->addRootCollection();
        $rootCollection->setVisible(1)->store();
        $institutesRole->store();
    }
    $instituteCollection = $rootCollection->addLastChild();
    $instituteCollection->setVisible(1)->setName($instituteName)->store();
}
$doc->addCollection($instituteCollection);
$doc->setPublishedYear('2010');
$doc->setPublishedDate('2010-09-28');
$doc->setPublisherName('The Walt Disney Company');
$doc->setPublisherPlace('Burbank, CA');
$doc->setCompletedYear('2010');
$doc->setCompletedDate('2010-09-27');
$opusThreeId = $doc->addIdentifierOpus3();
$opusThreeId->setValue('1234');
// empty URN will be automaticaly replace by new URN.
$urn = $doc->addIdentifierUrn();
$urn->setValue('urn:nbn:de:kobv:nn-opus-173');
$isbn = $doc->addIdentifierIsbn();
$isbn->setValue('978-3-86680-192-9');
$issn = $doc->addIdentifierIssn();
$issn->setValue('1234-5678');
$doc->addIdentifierOpac()->setValue('OPAC-ID 001 1237890654');
// Valid Arxiv-Identifier from ArXiv.org Homepage: http://arxiv.org/help/arxiv_identifier
$arxiv = $doc->addIdentifierArxiv();
$arxiv->setValue('arXiv:0706.0001');
// Valid DOI Identifier from DOI Homepage: http://www.doi.org/
$doi = $doc->addIdentifierDoi();
$doi->setValue('10.1000/182');
开发者ID:belapp,项目名称:opus4-application,代码行数:31,代码来源:create_all_fields_document.php

示例4:

    if (is_null($rootCollection) === true) {
        $rootCollection = $institutesRole->addRootCollection();
        $rootCollection->setVisible(1)->store();
        $institutesRole->store();
    }
    $instituteCollection = $rootCollection->addLastChild();
    $instituteCollection->setVisible(1)->setName($instituteName)->store();
}
$doc->addCollection($instituteCollection);
$doc->setPublishedYear('2010');
$doc->setPublishedDate('2010-09-28');
$doc->setPublisherName('The Walt Disney Company');
$doc->setPublisherPlace('Burbank, CA');
$doc->setCompletedYear('2010');
$doc->setCompletedDate('2010-09-27');
$o3id = $doc->addIdentifierOpus3();
$o3id->setValue('1234');
// empty URN will be automaticaly replace by new URN.
$urn = $doc->addIdentifierUrn();
$urn->setValue('urn:nbn:de:kobv:nn-opus-173');
$isbn = $doc->addIdentifierIsbn();
$isbn->setValue('978-3-86680-192-9');
$issn = $doc->addIdentifierIssn();
$issn->setValue('1234-5678');
$doc->addIdentifierOpac()->setValue('OPAC-ID 001 1237890654');
// Valid Arxiv-Identifier from ArXiv.org Homepage: http://arxiv.org/help/arxiv_identifier
$arxiv = $doc->addIdentifierArxiv();
$arxiv->setValue('arXiv:0706.0001');
// Valid DOI Identifier from DOI Homepage: http://www.doi.org/
$doi = $doc->addIdentifierDoi();
$doi->setValue('10.1000/182');
开发者ID:alexukua,项目名称:opus4,代码行数:31,代码来源:create_all_fields_document.php


注:本文中的Opus_Document::addIdentifierOpus3方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。