forked from D-Net/dnet-hadoop
added accessrights and hostedby
This commit is contained in:
parent
f6c37656c9
commit
aef88f9e5c
|
@ -195,6 +195,8 @@ object BioschemaToOAFTransformation {
|
||||||
throw new RuntimeException("Url not found")
|
throw new RuntimeException("Url not found")
|
||||||
}
|
}
|
||||||
instance.setCollectedfrom(collectedFromMap(datasourceKey))
|
instance.setCollectedfrom(collectedFromMap(datasourceKey))
|
||||||
|
instance.setHostedby(collectedFromMap(datasourceKey))
|
||||||
|
|
||||||
instance.setPid(result.getPid)
|
instance.setPid(result.getPid)
|
||||||
|
|
||||||
result.setId(IdentifierFactory.createIdentifier(result))
|
result.setId(IdentifierFactory.createIdentifier(result))
|
||||||
|
@ -240,6 +242,15 @@ object BioschemaToOAFTransformation {
|
||||||
finalAlternativeIdentifiers = List(alternativeIdentifiers) ::: List(defaultAlternatedIdentifer)
|
finalAlternativeIdentifiers = List(alternativeIdentifiers) ::: List(defaultAlternatedIdentifer)
|
||||||
instance.setAlternateIdentifier(finalAlternativeIdentifiers.asJava)
|
instance.setAlternateIdentifier(finalAlternativeIdentifiers.asJava)
|
||||||
|
|
||||||
|
val access_rights_qualifier =
|
||||||
|
OafMapperUtils.accessRight(
|
||||||
|
ModelConstants.UNKNOWN,
|
||||||
|
ModelConstants.NOT_AVAILABLE,
|
||||||
|
ModelConstants.DNET_ACCESS_MODES,
|
||||||
|
ModelConstants.DNET_ACCESS_MODES
|
||||||
|
)
|
||||||
|
instance.setAccessright(access_rights_qualifier)
|
||||||
|
|
||||||
if (exportLinks) {
|
if (exportLinks) {
|
||||||
val rels: List[RelatedIdentifierType] = for {
|
val rels: List[RelatedIdentifierType] = for {
|
||||||
JObject(relIdentifier) <- json \\ "relatedIdentifiers"
|
JObject(relIdentifier) <- json \\ "relatedIdentifiers"
|
||||||
|
|
Loading…
Reference in New Issue