excluded author and author_contact from serialization/deserialization
git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/data-catalogue/grsf-publisher-ws@132964 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
45ac9feb0b
commit
1c2d7f0246
|
@ -11,12 +11,14 @@ import org.gcube.data_catalogue.grsf_publish_ws.utils.groups.Source;
|
||||||
import org.gcube.data_catalogue.grsf_publish_ws.utils.groups.Status;
|
import org.gcube.data_catalogue.grsf_publish_ws.utils.groups.Status;
|
||||||
import org.gcube.data_catalogue.grsf_publish_ws.utils.groups.Type;
|
import org.gcube.data_catalogue.grsf_publish_ws.utils.groups.Type;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Information that both Stock and Fishery must contain
|
* Information that both Stock and Fishery must contain
|
||||||
* @author Costantino Perciante at ISTI-CNR (costantino.perciante@isti.cnr.it)
|
* @author Costantino Perciante at ISTI-CNR (costantino.perciante@isti.cnr.it)
|
||||||
*/
|
*/
|
||||||
|
@JsonIgnoreProperties(value = {"author", "author_contact"}, ignoreUnknown = true) // ignore in serialization/deserialization
|
||||||
public class Common {
|
public class Common {
|
||||||
|
|
||||||
@JsonProperty("description")
|
@JsonProperty("description")
|
||||||
|
@ -24,14 +26,14 @@ public class Common {
|
||||||
|
|
||||||
@JsonProperty("license")
|
@JsonProperty("license")
|
||||||
private String license;
|
private String license;
|
||||||
|
|
||||||
@JsonProperty("author") // @JsonIgnoreProperties(ignoreUnknown=true) // ignore in serialization/deserialization
|
@JsonProperty("author")// filled automatically by the server
|
||||||
private String author;
|
private String author;
|
||||||
|
|
||||||
@JsonProperty("version")
|
@JsonProperty("version")
|
||||||
private Long version;
|
private Long version;
|
||||||
|
|
||||||
@JsonProperty("author_contact")
|
@JsonProperty("author_contact")// filled automatically by the service
|
||||||
private String authorContact;
|
private String authorContact;
|
||||||
|
|
||||||
@JsonProperty("maintainer")
|
@JsonProperty("maintainer")
|
||||||
|
@ -147,7 +149,7 @@ public class Common {
|
||||||
public void setVersion(Long version) {
|
public void setVersion(Long version) {
|
||||||
this.version = version;
|
this.version = version;
|
||||||
}
|
}
|
||||||
|
|
||||||
public String getAuthorContact() {
|
public String getAuthorContact() {
|
||||||
return authorContact;
|
return authorContact;
|
||||||
}
|
}
|
||||||
|
|
|
@ -108,6 +108,9 @@ public class JTests {
|
||||||
FisheryRecord recordFishery = new FisheryRecord();
|
FisheryRecord recordFishery = new FisheryRecord();
|
||||||
recordFishery.setType(Type.Fishing_Description);
|
recordFishery.setType(Type.Fishing_Description);
|
||||||
recordFishery.setDatabaseSources(Source.FIRMS);
|
recordFishery.setDatabaseSources(Source.FIRMS);
|
||||||
|
recordFishery.setAuthor("Costantino Perciante");
|
||||||
|
recordFishery.setMaintainer("Costantino Perciante");
|
||||||
|
recordFishery.setAuthorContact("costantino.perciante@isti.cnr.it");
|
||||||
recordFishery.setStatus(Status.Pending);
|
recordFishery.setStatus(Status.Pending);
|
||||||
recordFishery.setVersion(new Long(10));
|
recordFishery.setVersion(new Long(10));
|
||||||
HashMap<String, String> extras = new HashMap<String, String>();
|
HashMap<String, String> extras = new HashMap<String, String>();
|
||||||
|
|
Loading…
Reference in New Issue