public class ZenodoSoftwareVersionExporter extends SoftwareVersionExporter
| Modifier and Type | Field and Description |
|---|---|
protected String |
accessToken |
static String |
ADDITIONAL_HTML_DESCRIPTION_CONFIG_FIELD_NAME |
static String |
COMMUNITIES_FIELD_NAME |
static String |
DEPOSITION_PATH |
static String |
DEPOSITIONS_COLLECTION_PATH |
static String |
DEPOSTION_EDIT_PATH |
static String |
DEPOSTION_FILES_PATH |
static String |
DEPOSTION_NEW_VERSION_PATH |
static String |
DEPOSTION_PUBLISH_PATH |
protected String |
doiBaseURL |
static String |
EXPORT_FILENAME_EXTENSION |
static String |
GUCBE_ZENODO_SOFTWARE_DEPOSIT |
static String |
HTML_DESCRIPTION_CONFIG_FIELD_NAME |
static String |
METADATA_FIELD_NAME |
static String |
RECORD_PATH |
protected org.gcube.com.fasterxml.jackson.databind.JsonNode |
response |
static String |
SKIP_GRANTS_CONFIG_FIELD_NAME |
protected URL |
zenodoBaseURL |
protected String |
zenodoID |
availableExporters, exporterConfig, exportFileNameExtension, first, globalConfig, last, outputDirectory, softwareVersionConfig| Constructor and Description |
|---|
ZenodoSoftwareVersionExporter() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
addFilesToDeposition(List<File> files) |
void |
create() |
protected String |
createZenodoDOIURLFromID(String id) |
protected void |
deletePreviousFiles()
Remove previous depositionFiles
|
void |
export() |
protected void |
finalize() |
protected Map<String,String> |
getAccessTokenQueryParamters() |
protected String |
getConfig(String propertyName) |
protected org.gcube.com.fasterxml.jackson.databind.node.ObjectNode |
getObjectNode() |
File |
getOutputFile() |
org.gcube.com.fasterxml.jackson.databind.JsonNode |
getResponse(HttpURLConnection connection) |
protected StringBuilder |
getStringBuilder(InputStream inputStream) |
protected void |
getZenodoConnectionConfig() |
protected String |
getZenodoIDFromDOIURL(String doiURL) |
protected String |
getZenodoIDFromDOIURL(URL doiURL) |
void |
newVersion() |
protected void |
publishToZenodo() |
void |
update() |
protected void |
updateMetadata() |
protected void |
writeObjectNodeToFile(org.gcube.com.fasterxml.jackson.databind.node.ObjectNode toBeExported,
File file) |
getAvailableExporters, getExporterConfig, getGlobalConfig, getSoftwareVersionConfig, setExporterConfig, setFirst, setGlobalConfig, setLast, setOutputDirectory, setSoftwareVersionConfigpublic static final String EXPORT_FILENAME_EXTENSION
public static final String GUCBE_ZENODO_SOFTWARE_DEPOSIT
public static final String HTML_DESCRIPTION_CONFIG_FIELD_NAME
public static final String ADDITIONAL_HTML_DESCRIPTION_CONFIG_FIELD_NAME
public static final String SKIP_GRANTS_CONFIG_FIELD_NAME
public static final String METADATA_FIELD_NAME
public static final String COMMUNITIES_FIELD_NAME
public static final String DEPOSITIONS_COLLECTION_PATH
public static final String DEPOSITION_PATH
public static final String RECORD_PATH
public static final String DEPOSTION_FILES_PATH
public static final String DEPOSTION_NEW_VERSION_PATH
public static final String DEPOSTION_EDIT_PATH
public static final String DEPOSTION_PUBLISH_PATH
protected URL zenodoBaseURL
protected String accessToken
protected String zenodoID
protected org.gcube.com.fasterxml.jackson.databind.JsonNode response
protected String doiBaseURL
protected void addFilesToDeposition(List<File> files) throws Exception
Exceptionprotected void finalize()
throws Exception
protected StringBuilder getStringBuilder(InputStream inputStream) throws IOException
IOExceptionpublic org.gcube.com.fasterxml.jackson.databind.JsonNode getResponse(HttpURLConnection connection) throws Exception
Exceptionprotected String createZenodoDOIURLFromID(String id) throws MalformedURLException
MalformedURLExceptionprotected void deletePreviousFiles()
throws Exception
Exceptionprotected void getZenodoConnectionConfig()
throws Exception
Exceptionpublic void export()
throws Exception
export in class SoftwareVersionExporterExceptionprotected org.gcube.com.fasterxml.jackson.databind.node.ObjectNode getObjectNode()
throws Exception
Exceptionprotected void writeObjectNodeToFile(org.gcube.com.fasterxml.jackson.databind.node.ObjectNode toBeExported,
File file)
throws Exception
Exceptionpublic File getOutputFile() throws Exception
getOutputFile in class SoftwareVersionExporterExceptionCopyright © 2023. All Rights Reserved.