From f26382fa5157eacfabdad31f67a9903b7e0dd44e Mon Sep 17 00:00:00 2001 From: "miriam.baglioni" Date: Wed, 19 Aug 2020 11:45:23 +0200 Subject: [PATCH] extends the instance with parameters collectedfrom and hostedby to be dumps only for communities --- .../dump/oaf/community/CommunityInstance.java | 39 ++++++++++++++++++- 1 file changed, 38 insertions(+), 1 deletion(-) diff --git a/dhp-schemas/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/community/CommunityInstance.java b/dhp-schemas/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/community/CommunityInstance.java index 03c770e84..f520ef04f 100644 --- a/dhp-schemas/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/community/CommunityInstance.java +++ b/dhp-schemas/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/community/CommunityInstance.java @@ -1,4 +1,41 @@ package eu.dnetlib.dhp.schema.dump.oaf.community; -public class CommunityInstance { +import eu.dnetlib.dhp.schema.dump.oaf.Instance; +import eu.dnetlib.dhp.schema.dump.oaf.KeyValue; + +/** + * It extends eu.dnetlib.dhp.dump.oaf.Instance with values related to the community dump. In the Result dump this information + * is not present because it is dumped as a set of relations between the result and the datasource. + * - hostedby of type eu.dnetlib.dhp.schema.dump.oaf.KeyValue to store the information about the source from which the instance can be + * viewed or downloaded. It is mapped against the hostedby parameter of the instance to be dumped and + * - key corresponds to hostedby.key + * - value corresponds to hostedby.value + * - collectedfrom of type eu.dnetlib.dhp.schema.dump.oaf.KeyValue to store the information about the source from which the instance has been + * collected. It is mapped against the collectedfrom parameter of the instance to be dumped and + * - key corresponds to collectedfrom.key + * - value corresponds to collectedfrom.value + */ +public class CommunityInstance extends Instance { + private KeyValue hostedby; + private KeyValue collectedfrom; + + + public KeyValue getHostedby() { + return hostedby; + } + + + public void setHostedby(KeyValue hostedby) { + this.hostedby = hostedby; + } + + + public KeyValue getCollectedfrom() { + return collectedfrom; + } + + + public void setCollectedfrom(KeyValue collectedfrom) { + this.collectedfrom = collectedfrom; + } }