From e4a9f3e4e5c212d1442f7d646ad7ccde6f35f09e Mon Sep 17 00:00:00 2001 From: "francesco.mangiacrapa" Date: Wed, 29 Sep 2021 11:36:13 +0200 Subject: [PATCH] Added FileSetPathsDV --- .../ConvertToDataViewModel.java | 21 +++++- .../shared/products/paths/FileSetPathsDV.java | 66 +++++++++++++++++++ 2 files changed, 86 insertions(+), 1 deletion(-) create mode 100644 src/main/java/org/gcube/application/geoportalcommon/shared/products/paths/FileSetPathsDV.java diff --git a/src/main/java/org/gcube/application/geoportalcommon/ConvertToDataViewModel.java b/src/main/java/org/gcube/application/geoportalcommon/ConvertToDataViewModel.java index cadd22a..600c5e6 100644 --- a/src/main/java/org/gcube/application/geoportalcommon/ConvertToDataViewModel.java +++ b/src/main/java/org/gcube/application/geoportalcommon/ConvertToDataViewModel.java @@ -28,6 +28,7 @@ import org.gcube.application.geoportalcommon.shared.products.model.RelazioneScav import org.gcube.application.geoportalcommon.shared.products.model.UploadedImageDV; import org.gcube.application.geoportalcommon.shared.products.model.ValidationReportDV; import org.gcube.application.geoportalcommon.shared.products.model.ValidationReportDV.ValidationStatus; +import org.gcube.application.geoportalcommon.shared.products.paths.FileSetPathsDV; import org.gcube.application.geoportalcommon.util.DateUtils; import org.gcube.application.geoportalcommon.util.URLParserUtil; import org.slf4j.Logger; @@ -524,7 +525,7 @@ public class ConvertToDataViewModel { theLayerConessione.setTopicCategory(layerConcessione.getTopicCategory()); theLayerConessione.setValutazioneQualita(layerConcessione.getValutazioneQualita()); theLayerConessione.setRefersTo(refersToBaseConcessione); - + List actContent = layerConcessione.getActualContent(); if (actContent != null && actContent.size() > 0) { List listWsContent = new ArrayList(); @@ -564,6 +565,24 @@ public class ConvertToDataViewModel { return theOtherContent; } + public static FileSetPathsDV getFileSetPaths() { + + FileSetPathsDV fsp = new FileSetPathsDV(); + + LOG.info("readFileSetPaths called"); + List fileSetPaths = new ArrayList(); + fileSetPaths.add(Concessione.Paths.ABSTRACT_RELAZIONE); + fileSetPaths.add(Concessione.Paths.RELAZIONE); + fileSetPaths.add(Concessione.Paths.IMMAGINI); + fileSetPaths.add(Concessione.Paths.POSIZIONAMENTO); + fileSetPaths.add(Concessione.Paths.PIANTE); + + fsp.setFileSetPaths(fileSetPaths); + + return fsp; + + } + /** * To bound map. * diff --git a/src/main/java/org/gcube/application/geoportalcommon/shared/products/paths/FileSetPathsDV.java b/src/main/java/org/gcube/application/geoportalcommon/shared/products/paths/FileSetPathsDV.java new file mode 100644 index 0000000..28c9f01 --- /dev/null +++ b/src/main/java/org/gcube/application/geoportalcommon/shared/products/paths/FileSetPathsDV.java @@ -0,0 +1,66 @@ +package org.gcube.application.geoportalcommon.shared.products.paths; + +import java.io.Serializable; +import java.util.ArrayList; +import java.util.List; + +/** + * The Class FileSetPathsDV. + * + * @author Francesco Mangiacrapa at ISTI-CNR francesco.mangiacrapa@isti.cnr.it + * + * Sep 29, 2021 + */ +public class FileSetPathsDV implements Serializable { + + /** + * + */ + private static final long serialVersionUID = 7494678009053802818L; + List fileSetPaths = new ArrayList(); + + /** + * Instantiates a new file set paths DV. + */ + public FileSetPathsDV() { + + } + + /** + * Instantiates a new file set paths DV. + * + * @param fileSetPaths the file set paths + */ + public FileSetPathsDV(List fileSetPaths) { + super(); + this.fileSetPaths = fileSetPaths; + } + + /** + * Gets the file set paths. + * + * @return the file set paths + */ + public List getFileSetPaths() { + return fileSetPaths; + } + + /** + * Sets the file set paths. + * + * @param fileSetPaths the new file set paths + */ + public void setFileSetPaths(List fileSetPaths) { + this.fileSetPaths = fileSetPaths; + } + + @Override + public String toString() { + StringBuilder builder = new StringBuilder(); + builder.append("FileSetPathsDV [fileSetPaths="); + builder.append(fileSetPaths); + builder.append("]"); + return builder.toString(); + } + +}