142 lines
3.3 KiB
Java
142 lines
3.3 KiB
Java
package org.gcube.common.software.model;
|
|
|
|
import java.net.URL;
|
|
import java.util.List;
|
|
import java.util.Map;
|
|
import java.util.Set;
|
|
|
|
import org.gcube.com.fasterxml.jackson.annotation.JsonIgnore;
|
|
import org.gcube.com.fasterxml.jackson.annotation.JsonProperty;
|
|
import org.gcube.com.fasterxml.jackson.databind.JsonNode;
|
|
import org.gcube.com.fasterxml.jackson.databind.node.ArrayNode;
|
|
import org.gcube.com.fasterxml.jackson.databind.node.ObjectNode;
|
|
|
|
/**
|
|
* @author Luca Frosini (ISTI - CNR)
|
|
*/
|
|
public class SoftwareGlobalConfig {
|
|
|
|
public static final String NAME_PROPERTY_NAME = "name";
|
|
public static final String GROUP_PROPERTY_NAME = "group";
|
|
public static final String TITLE_PROPERTY_NAME = "title";
|
|
public static final String LICENSE_PROPERTY_NAME = "license";
|
|
public static final String KEYWORDS_PROPERTY_NAME = "keywords";
|
|
public static final String DESCRIPTION_PROPERTY_NAME = "description";
|
|
public static final String AUTHORS_PROPERTY_NAME = "authors";
|
|
public static final String FILES_PROPERTY_NAME = "files";
|
|
public static final String CODE_LOCATION_PROPERTY_NAME = "code_location";
|
|
public static final String DOI_URL_PROPERTY_NAME = "doi_url";
|
|
public static final String GRANTS_PROPERTY_NAME = "grants";
|
|
public static final String PUBLISHERS_PROPERTY_NAME = "publishers";
|
|
public static final String EXPORTERS_PROPERTY_NAME = "exporters";
|
|
|
|
@JsonIgnore
|
|
protected ObjectNode originalJson;
|
|
|
|
@JsonProperty(NAME_PROPERTY_NAME)
|
|
protected String name;
|
|
|
|
@JsonProperty(GROUP_PROPERTY_NAME)
|
|
protected String group;
|
|
|
|
@JsonProperty(TITLE_PROPERTY_NAME)
|
|
protected String title;
|
|
|
|
@JsonProperty(LICENSE_PROPERTY_NAME)
|
|
protected JsonNode license;
|
|
|
|
@JsonProperty(KEYWORDS_PROPERTY_NAME)
|
|
protected Set<String> keywords;
|
|
|
|
@JsonProperty(DESCRIPTION_PROPERTY_NAME)
|
|
protected String description;
|
|
|
|
@JsonProperty(AUTHORS_PROPERTY_NAME)
|
|
protected ArrayNode authors;
|
|
|
|
@JsonProperty(FILES_PROPERTY_NAME)
|
|
protected List<SoftwareVersionFile> files;
|
|
|
|
@JsonProperty(CODE_LOCATION_PROPERTY_NAME)
|
|
protected String codeLocation;
|
|
|
|
@JsonProperty(DOI_URL_PROPERTY_NAME)
|
|
protected URL doiURL;
|
|
|
|
@JsonProperty(GRANTS_PROPERTY_NAME)
|
|
protected JsonNode grants;
|
|
|
|
@JsonProperty(PUBLISHERS_PROPERTY_NAME)
|
|
protected Map<String,ProcessorConfig> publishers;
|
|
|
|
@JsonProperty(EXPORTERS_PROPERTY_NAME)
|
|
protected Map<String,ProcessorConfig> exporters;
|
|
|
|
@JsonIgnore
|
|
public ObjectNode getOriginalJson() {
|
|
return originalJson;
|
|
}
|
|
|
|
@JsonIgnore
|
|
public void setOriginalJson(ObjectNode originalJson) {
|
|
this.originalJson = originalJson;
|
|
}
|
|
|
|
public String getName() {
|
|
return name;
|
|
}
|
|
|
|
public String getGroup() {
|
|
return group;
|
|
}
|
|
|
|
public String getTitle() {
|
|
return title;
|
|
}
|
|
|
|
public JsonNode getLicense() {
|
|
return license;
|
|
}
|
|
|
|
public Set<String> getKeywords() {
|
|
return keywords;
|
|
}
|
|
|
|
public String getDescription() {
|
|
return description;
|
|
}
|
|
|
|
public ArrayNode getAuthors() {
|
|
return authors;
|
|
}
|
|
|
|
public List<SoftwareVersionFile> getFiles() {
|
|
return files;
|
|
}
|
|
|
|
public String getCodeLocation() {
|
|
return codeLocation;
|
|
}
|
|
|
|
public URL getDOIURL() {
|
|
return doiURL;
|
|
}
|
|
|
|
public void setDOIURL(URL doiURL) {
|
|
this.doiURL = doiURL;
|
|
}
|
|
|
|
public JsonNode getGrants() {
|
|
return grants;
|
|
}
|
|
|
|
public Map<String,ProcessorConfig> getPublishers() {
|
|
return publishers;
|
|
}
|
|
|
|
public Map<String,ProcessorConfig> getExporters() {
|
|
return exporters;
|
|
}
|
|
|
|
}
|