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 b973f5b..4abbf2f 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 @@ -2,26 +2,15 @@ package eu.dnetlib.dhp.schema.dump.oaf; /** - * AccessRight. Used to represent the result access rights. It extends the eu.dnet.lib.dhp.schema.dump.oaf.Qualifier - * element with a parameter scheme of type String to store the scheme. Values for this element are found against the - * COAR access right scheme. The classid of the element accessright in eu.dnetlib.dhp.schema.oaf.Result is used to get - * the COAR corresponding code whose value will be used to set the code parameter. The COAR label corresponding to the - * COAR code will be used to set the label parameter. The scheme value will always be the one referring to the COAR - * access right scheme + * AccessRight. Used to represent the result access rights. It extends the eu.dnet.lib.dhp.schema.dump.oaf.BestAccessRight + * element with value for the openaccess route */ -public class AccessRight extends Qualifier { +public class AccessRight extends BestAccessRight { + - private String scheme; private OpenAccessRoute openAccessRoute ; - public String getScheme() { - return scheme; - } - - public void setScheme(String scheme) { - this.scheme = scheme; - } public static AccessRight newInstance(String code, String label, String scheme) { AccessRight ar = new AccessRight(); diff --git a/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/BestAccessRight.java b/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/BestAccessRight.java new file mode 100644 index 0000000..71a3c34 --- /dev/null +++ b/src/main/java/eu/dnetlib/dhp/schema/dump/oaf/BestAccessRight.java @@ -0,0 +1,31 @@ +package eu.dnetlib.dhp.schema.dump.oaf; + +/** + * BestAccessRight. Used to represent the result best access rights. It extends the eu.dnet.lib.dhp.schema.dump.oaf.Qualifier + * element with a parameter scheme of type String to store the scheme. Values for this element are found against the + * COAR access right scheme. The classid of the element accessright in eu.dnetlib.dhp.schema.oaf.Result is used to get + * the COAR corresponding code whose value will be used to set the code parameter. The COAR label corresponding to the + * COAR code will be used to set the label parameter. The scheme value will always be the one referring to the COAR + * access right scheme + */ + +public class BestAccessRight extends Qualifier { + + private String scheme; + + public String getScheme() { + return scheme; + } + + public void setScheme(String scheme) { + this.scheme = scheme; + } + + public static BestAccessRight newInstance(String code, String label, String scheme) { + BestAccessRight ar = new BestAccessRight(); + ar.setCode(code); + ar.setLabel(label); + ar.setScheme(scheme); + return ar; + } +}