forked from antonis.lempesis/dnet-hadoop
Merge branch 'dhp_oaf_model' of https://code-repo.d4science.org/D-Net/dnet-hadoop into dhp_oaf_model
This commit is contained in:
commit
7f2b4f227d
|
@ -168,6 +168,9 @@ case object Crossref2Oaf {
|
||||||
instance.setLicense(l.head)
|
instance.setLicense(l.head)
|
||||||
|
|
||||||
|
|
||||||
|
// Ticket #6281 added pid to Instance
|
||||||
|
instance.setPid(result.getPid.asScala.filter(p => p.getQualifier.getClassid.equalsIgnoreCase("doi")).asJava)
|
||||||
|
|
||||||
val has_review = (json \ "relation" \"has-review" \ "id")
|
val has_review = (json \ "relation" \"has-review" \ "id")
|
||||||
|
|
||||||
if(has_review != JNothing) {
|
if(has_review != JNothing) {
|
||||||
|
|
|
@ -170,6 +170,9 @@ case object ConversionUtil {
|
||||||
else
|
else
|
||||||
i.setUrl(List(s"https://academic.microsoft.com/#/detail/${extractMagIdentifier(pub.getOriginalId.asScala)}").asJava)
|
i.setUrl(List(s"https://academic.microsoft.com/#/detail/${extractMagIdentifier(pub.getOriginalId.asScala)}").asJava)
|
||||||
|
|
||||||
|
// Ticket #6281 added pid to Instance
|
||||||
|
i.setPid(pub.getPid.asScala.filter(p => p.getQualifier.getClassid.equalsIgnoreCase("doi")).asJava)
|
||||||
|
|
||||||
i.setCollectedfrom(createMAGCollectedFrom())
|
i.setCollectedfrom(createMAGCollectedFrom())
|
||||||
pub.setInstance(List(i).asJava)
|
pub.setInstance(List(i).asJava)
|
||||||
pub
|
pub
|
||||||
|
|
|
@ -49,6 +49,9 @@ object UnpayWallToOAF {
|
||||||
i.setAccessright(getOpenAccessQualifier())
|
i.setAccessright(getOpenAccessQualifier())
|
||||||
i.setUrl(List(oaLocation.url.get).asJava)
|
i.setUrl(List(oaLocation.url.get).asJava)
|
||||||
|
|
||||||
|
// Ticket #6281 added pid to Instance
|
||||||
|
i.setPid(pub.getPid.asScala.filter(p => p.getQualifier.getClassid.equalsIgnoreCase("doi")).asJava)
|
||||||
|
|
||||||
if (oaLocation.license.isDefined)
|
if (oaLocation.license.isDefined)
|
||||||
i.setLicense(asField(oaLocation.license.get))
|
i.setLicense(asField(oaLocation.license.get))
|
||||||
pub.setInstance(List(i).asJava)
|
pub.setInstance(List(i).asJava)
|
||||||
|
|
|
@ -343,6 +343,9 @@ object DLIToOAF {
|
||||||
val instance_urls = if (fpids.head.length < 5) s"https://www.rcsb.org/structure/${fpids.head}" else s"https://dx.doi.org/${fpids.head}"
|
val instance_urls = if (fpids.head.length < 5) s"https://www.rcsb.org/structure/${fpids.head}" else s"https://dx.doi.org/${fpids.head}"
|
||||||
|
|
||||||
val i: Instance = createInstance(instance_urls, firstInstanceOrNull(d.getInstance()), result.getDateofacceptance, true)
|
val i: Instance = createInstance(instance_urls, firstInstanceOrNull(d.getInstance()), result.getDateofacceptance, true)
|
||||||
|
|
||||||
|
// Ticket #6281 added pid to Instance
|
||||||
|
i.setPid(result.getPid)
|
||||||
if (i != null)
|
if (i != null)
|
||||||
result.setInstance(List(i).asJava)
|
result.setInstance(List(i).asJava)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue