From 28ef0d2fa366ba1ac15c5eb5636ce86b196e1709 Mon Sep 17 00:00:00 2001 From: "miriam.baglioni" Date: Thu, 5 Aug 2021 12:04:10 +0200 Subject: [PATCH] extended the schema of the dump to mirror the changes in the model. Added openaccessroute at the level of the instance inside the AccessRight element. Added the information of the pid and the alternate indentifiers at the level of the instance, and added the bipFinder measures at the level of the dumper result. Also correct a typo in the Measure class in the oaf model --- .../dhp/schema/dump/oaf/AccessRight.java | 10 ++++++++ .../dnetlib/dhp/schema/dump/oaf/Instance.java | 23 +++++++++++++++++++ .../dhp/schema/dump/oaf/OpenAccessRoute.java | 13 +++++++++++ .../dnetlib/dhp/schema/dump/oaf/Result.java | 11 +++++++++ .../eu/dnetlib/dhp/schema/oaf/Measure.java | 2 +- 5 files changed, 58 insertions(+), 1 deletion(-) create mode 100644 src/main/java/eu/dnetlib/dhp/schema/dump/oaf/OpenAccessRoute.java diff --git a/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/AccessRight.java b/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/AccessRight.java index f28c544..b973f5b 100644 --- a/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/AccessRight.java +++ b/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/AccessRight.java @@ -13,6 +13,8 @@ public class AccessRight extends Qualifier { private String scheme; + private OpenAccessRoute openAccessRoute ; + public String getScheme() { return scheme; } @@ -28,4 +30,12 @@ public class AccessRight extends Qualifier { ar.setScheme(scheme); return ar; } + + public OpenAccessRoute getOpenAccessRoute() { + return openAccessRoute; + } + + public void setOpenAccessRoute(OpenAccessRoute openAccessRoute) { + this.openAccessRoute = openAccessRoute; + } } diff --git a/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/Instance.java b/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/Instance.java index c4ec7b1..826e65c 100644 --- a/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/Instance.java +++ b/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/Instance.java @@ -16,9 +16,16 @@ import java.util.List; * String to store information abour tthe review status of the instance. Possible values are 'Unknown', * 'nonPeerReviewed', 'peerReviewed'. It corresponds to refereed.classname of the instance to be dumped * - articleprocessingcharge of type APC to store the article processing charges possibly associated to the instance + * -pid of type List that is the list of pids associated to the result coming from authoritative sources for that pid + * -alternateIdentifier of type List that is the list of pids associated to the result coming from NON authoritative + * sources for that pid */ public class Instance implements Serializable { + private List pid; + + private List alternateIdentifier; + private String license; private AccessRight accessright; @@ -88,4 +95,20 @@ public class Instance implements Serializable { public void setArticleprocessingcharge(APC articleprocessingcharge) { this.articleprocessingcharge = articleprocessingcharge; } + + public List getPid() { + return pid; + } + + public void setPid(List pid) { + this.pid = pid; + } + + public List getAlternateIdentifier() { + return alternateIdentifier; + } + + public void setAlternateIdentifier(List alternateIdentifier) { + this.alternateIdentifier = alternateIdentifier; + } } diff --git a/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/OpenAccessRoute.java b/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/OpenAccessRoute.java new file mode 100644 index 0000000..fbef655 --- /dev/null +++ b/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/OpenAccessRoute.java @@ -0,0 +1,13 @@ + +package eu.dnetlib.dhp.schema.dump.oaf; + +/** + * This Enum models the OpenAccess status, currently including only the values from Unpaywall + * + * https://support.unpaywall.org/support/solutions/articles/44001777288-what-do-the-types-of-oa-status-green-gold-hybrid-and-bronze-mean- + */ +public enum OpenAccessRoute { + + gold, green, hybrid, bronze + +} diff --git a/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/Result.java b/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/Result.java index 88ab2c3..1981776 100644 --- a/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/Result.java +++ b/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/Result.java @@ -62,9 +62,12 @@ import eu.dnetlib.dhp.schema.dump.oaf.community.Project; * to store information about the time OpenAIRE collected the record. It corresponds to dateofcollection of the result * represented in the internal model - lasteupdatetimestamp of type String to store the timestamp of the last update of * the record. It corresponds to lastupdatetimestamp of the resord represented in the internal model + * -measure list to represent the measure of beepFinder. It corresponds to measures in the model */ public class Result implements Serializable { + private List measures; + private List author; // resulttype allows subclassing results into publications | datasets | software @@ -376,4 +379,12 @@ public class Result implements Serializable { public void setGeolocation(List geolocation) { this.geolocation = geolocation; } + + public List getMeasures() { + return measures; + } + + public void setMeasures(List measures) { + this.measures = measures; + } } diff --git a/src/main/java/eu/dnetlib/dhp/schema/oaf/Measure.java b/src/main/java/eu/dnetlib/dhp/schema/oaf/Measure.java index c0c14d1..e88ff73 100644 --- a/src/main/java/eu/dnetlib/dhp/schema/oaf/Measure.java +++ b/src/main/java/eu/dnetlib/dhp/schema/oaf/Measure.java @@ -16,7 +16,7 @@ public class Measure { private String id; /** - * List of units associated with this measure. KeyValue provides a pair to store the laber (key) and the value, plus + * List of units associated with this measure. KeyValue provides a pair to store the label (key) and the value, plus * common provenance information. */ private List unit;