diff --git a/.classpath b/.classpath
index 46fd279..914dc7f 100644
--- a/.classpath
+++ b/.classpath
@@ -1,12 +1,12 @@
-
+
-
+
@@ -34,5 +34,5 @@
-
+
diff --git a/pom.xml b/pom.xml
index 407ed0c..2a449ec 100644
--- a/pom.xml
+++ b/pom.xml
@@ -12,7 +12,7 @@
org.gcube.portlets.user
data-miner-manager
- 1.6.0-SNAPSHOT
+ 1.7.0-SNAPSHOT
war
data-miner-manager
@@ -199,9 +199,6 @@
provided
-
-
@@ -242,6 +239,12 @@
ic-client
+
+
+ org.gcube.data.analysis
+ data-miner-manager-cl
+ [1.4.0-SNAPSHOT, 2.0.0-SNAPSHOT)
+
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/DataMinerManagerController.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/DataMinerManagerController.java
index 52fa497..9a1eadd 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/DataMinerManagerController.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/DataMinerManagerController.java
@@ -2,6 +2,12 @@ package org.gcube.portlets.user.dataminermanager.client;
import java.util.List;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.OutputData;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationData;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationId;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.OperatorsClassification;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.DataMinerWorkArea;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.ItemDescription;
import org.gcube.portlets.user.dataminermanager.client.common.EventBusProvider;
import org.gcube.portlets.user.dataminermanager.client.events.CancelComputationExecutionRequestEvent;
import org.gcube.portlets.user.dataminermanager.client.events.CancelExecutionFromComputationsRequestEvent;
@@ -30,14 +36,8 @@ import org.gcube.portlets.user.dataminermanager.client.type.MenuType;
import org.gcube.portlets.user.dataminermanager.client.util.InfoMessageBox;
import org.gcube.portlets.user.dataminermanager.client.util.UtilsGXT3;
import org.gcube.portlets.user.dataminermanager.shared.Constants;
-import org.gcube.portlets.user.dataminermanager.shared.data.OutputData;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationData;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationId;
import org.gcube.portlets.user.dataminermanager.shared.exception.SessionExpiredServiceException;
-import org.gcube.portlets.user.dataminermanager.shared.process.OperatorsClassification;
import org.gcube.portlets.user.dataminermanager.shared.session.UserInfo;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.DataMinerWorkArea;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.ItemDescription;
import com.allen_sauer.gwt.log.client.Log;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/computations/ComputationValueFileListPanel.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/computations/ComputationValueFileListPanel.java
index 0ee6c08..5ab69ca 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/computations/ComputationValueFileListPanel.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/computations/ComputationValueFileListPanel.java
@@ -1,9 +1,9 @@
package org.gcube.portlets.user.dataminermanager.client.computations;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationValue;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationValueFile;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationValueFileList;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationValueImage;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationValue;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationValueFile;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationValueFileList;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationValueImage;
import com.sencha.gxt.core.client.util.Margins;
import com.sencha.gxt.widget.core.client.container.SimpleContainer;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/computations/ComputationValueFilePanel.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/computations/ComputationValueFilePanel.java
index 01b2b8b..e0ed482 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/computations/ComputationValueFilePanel.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/computations/ComputationValueFilePanel.java
@@ -1,7 +1,7 @@
package org.gcube.portlets.user.dataminermanager.client.computations;
import org.gcube.portlets.user.dataminermanager.client.DataMinerManager;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationValueFile;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationValueFile;
import org.gcube.portlets.widgets.netcdfbasicwidgets.client.event.SelectVariableEvent;
import org.gcube.portlets.widgets.netcdfbasicwidgets.client.event.SelectVariableEvent.SelectVariableEventHandler;
import org.gcube.portlets.widgets.netcdfbasicwidgets.client.widgets.NetCDFPreviewDialog;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/computations/ComputationValueImagePanel.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/computations/ComputationValueImagePanel.java
index 215fdd5..882f133 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/computations/ComputationValueImagePanel.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/computations/ComputationValueImagePanel.java
@@ -1,7 +1,7 @@
package org.gcube.portlets.user.dataminermanager.client.computations;
import org.gcube.portlets.user.dataminermanager.client.DataMinerManager;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationValueImage;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationValueImage;
import com.google.gwt.user.client.ui.Image;
import com.sencha.gxt.core.client.util.Margins;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/computations/ComputationsExecutedPanel.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/computations/ComputationsExecutedPanel.java
index 80afc61..c4dc48b 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/computations/ComputationsExecutedPanel.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/computations/ComputationsExecutedPanel.java
@@ -21,7 +21,7 @@ import org.gcube.portlets.user.dataminermanager.client.type.DataMinerWorkAreaEle
import org.gcube.portlets.user.dataminermanager.client.util.UtilsGXT3;
import org.gcube.portlets.user.dataminermanager.shared.Constants;
import org.gcube.portlets.user.dataminermanager.shared.exception.SessionExpiredServiceException;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.ItemDescription;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.ItemDescription;
import org.gcube.portlets.widgets.workspaceuploader.client.WorkspaceUploadNotification.WorskpaceUploadNotificationListener;
import org.gcube.portlets.widgets.workspaceuploader.client.uploader.DialogUpload.UPLOAD_TYPE;
import org.gcube.portlets.widgets.workspaceuploader.client.uploader.dragdrop.MultipleDNDUpload;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/computations/ComputationsViewerPanel.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/computations/ComputationsViewerPanel.java
index 00b7187..d637f45 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/computations/ComputationsViewerPanel.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/computations/ComputationsViewerPanel.java
@@ -3,11 +3,11 @@ package org.gcube.portlets.user.dataminermanager.client.computations;
import java.util.LinkedHashMap;
import org.gcube.portlets.user.dataminermanager.client.util.UtilsGXT3;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationData;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationValue;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationValueFile;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationValueFileList;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationValueImage;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationData;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationValue;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationValueFile;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationValueFileList;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationValueImage;
import com.allen_sauer.gwt.log.client.Log;
import com.google.gwt.dom.client.Style.Unit;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/dataspace/InputDataSetsPanel.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/dataspace/InputDataSetsPanel.java
index ded016c..3673710 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/dataspace/InputDataSetsPanel.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/dataspace/InputDataSetsPanel.java
@@ -18,7 +18,7 @@ import org.gcube.portlets.user.dataminermanager.client.type.DataMinerWorkAreaEle
import org.gcube.portlets.user.dataminermanager.client.util.UtilsGXT3;
import org.gcube.portlets.user.dataminermanager.shared.Constants;
import org.gcube.portlets.user.dataminermanager.shared.exception.SessionExpiredServiceException;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.ItemDescription;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.ItemDescription;
import org.gcube.portlets.widgets.workspaceuploader.client.WorkspaceUploadNotification.WorskpaceUploadNotificationListener;
import org.gcube.portlets.widgets.workspaceuploader.client.uploader.DialogUpload.UPLOAD_TYPE;
import org.gcube.portlets.widgets.workspaceuploader.client.uploader.dragdrop.MultipleDNDUpload;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/dataspace/OutputDataSetsPanel.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/dataspace/OutputDataSetsPanel.java
index 37fe137..ded9266 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/dataspace/OutputDataSetsPanel.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/dataspace/OutputDataSetsPanel.java
@@ -18,7 +18,7 @@ import org.gcube.portlets.user.dataminermanager.client.type.DataMinerWorkAreaEle
import org.gcube.portlets.user.dataminermanager.client.util.UtilsGXT3;
import org.gcube.portlets.user.dataminermanager.shared.Constants;
import org.gcube.portlets.user.dataminermanager.shared.exception.SessionExpiredServiceException;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.ItemDescription;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.ItemDescription;
import org.gcube.portlets.widgets.workspaceuploader.client.WorkspaceUploadNotification.WorskpaceUploadNotificationListener;
import org.gcube.portlets.widgets.workspaceuploader.client.uploader.DialogUpload.UPLOAD_TYPE;
import org.gcube.portlets.widgets.workspaceuploader.client.uploader.dragdrop.MultipleDNDUpload;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/CancelComputationExecutionRequestEvent.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/CancelComputationExecutionRequestEvent.java
index e3cf3e2..f5da5e4 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/CancelComputationExecutionRequestEvent.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/CancelComputationExecutionRequestEvent.java
@@ -1,6 +1,6 @@
package org.gcube.portlets.user.dataminermanager.client.events;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationId;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationId;
import com.google.gwt.event.shared.EventHandler;
import com.google.gwt.event.shared.GwtEvent;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/CancelExecutionFromComputationsRequestEvent.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/CancelExecutionFromComputationsRequestEvent.java
index bc59447..e9e866f 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/CancelExecutionFromComputationsRequestEvent.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/CancelExecutionFromComputationsRequestEvent.java
@@ -1,6 +1,6 @@
package org.gcube.portlets.user.dataminermanager.client.events;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.ItemDescription;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.ItemDescription;
import com.google.gwt.event.shared.EventHandler;
import com.google.gwt.event.shared.GwtEvent;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/ComputationDataEvent.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/ComputationDataEvent.java
index b683b57..1aef89c 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/ComputationDataEvent.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/ComputationDataEvent.java
@@ -1,6 +1,6 @@
package org.gcube.portlets.user.dataminermanager.client.events;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationData;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationData;
import com.google.gwt.event.shared.EventHandler;
import com.google.gwt.event.shared.GwtEvent;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/ComputationDataRequestEvent.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/ComputationDataRequestEvent.java
index c0c6aa0..80030e2 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/ComputationDataRequestEvent.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/ComputationDataRequestEvent.java
@@ -1,6 +1,6 @@
package org.gcube.portlets.user.dataminermanager.client.events;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.ItemDescription;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.ItemDescription;
import com.google.gwt.event.shared.EventHandler;
import com.google.gwt.event.shared.GwtEvent;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/ComputationReadyEvent.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/ComputationReadyEvent.java
index 5ebae4e..0abdf0c 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/ComputationReadyEvent.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/ComputationReadyEvent.java
@@ -1,6 +1,6 @@
package org.gcube.portlets.user.dataminermanager.client.events;
-import org.gcube.portlets.user.dataminermanager.shared.process.Operator;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.Operator;
import com.google.gwt.event.shared.EventHandler;
import com.google.gwt.event.shared.GwtEvent;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/DataMinerWorkAreaEvent.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/DataMinerWorkAreaEvent.java
index fad2cd6..ce65372 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/DataMinerWorkAreaEvent.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/DataMinerWorkAreaEvent.java
@@ -2,7 +2,7 @@ package org.gcube.portlets.user.dataminermanager.client.events;
import org.gcube.portlets.user.dataminermanager.client.type.DataMinerWorkAreaEventType;
import org.gcube.portlets.user.dataminermanager.client.type.DataMinerWorkAreaRegionType;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.DataMinerWorkArea;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.DataMinerWorkArea;
import com.google.gwt.event.shared.EventHandler;
import com.google.gwt.event.shared.GwtEvent;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/DeleteItemRequestEvent.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/DeleteItemRequestEvent.java
index abc7cc7..5b66e26 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/DeleteItemRequestEvent.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/DeleteItemRequestEvent.java
@@ -1,7 +1,7 @@
package org.gcube.portlets.user.dataminermanager.client.events;
import org.gcube.portlets.user.dataminermanager.client.type.DataMinerWorkAreaElementType;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.ItemDescription;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.ItemDescription;
import com.google.gwt.event.shared.EventHandler;
import com.google.gwt.event.shared.GwtEvent;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/OperatorsClassificationEvent.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/OperatorsClassificationEvent.java
index c7527f5..59d4022 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/OperatorsClassificationEvent.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/OperatorsClassificationEvent.java
@@ -1,7 +1,7 @@
package org.gcube.portlets.user.dataminermanager.client.events;
import org.gcube.portlets.user.dataminermanager.client.type.OperatorsClassificationRequestType;
-import org.gcube.portlets.user.dataminermanager.shared.process.OperatorsClassification;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.OperatorsClassification;
import com.google.gwt.event.shared.EventHandler;
import com.google.gwt.event.shared.GwtEvent;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/OutputDataEvent.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/OutputDataEvent.java
index bbe9767..772a7b4 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/OutputDataEvent.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/OutputDataEvent.java
@@ -1,6 +1,6 @@
package org.gcube.portlets.user.dataminermanager.client.events;
-import org.gcube.portlets.user.dataminermanager.shared.data.OutputData;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.OutputData;
import com.google.gwt.event.shared.EventHandler;
import com.google.gwt.event.shared.GwtEvent;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/OutputDataRequestEvent.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/OutputDataRequestEvent.java
index 9fe91df..643be19 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/OutputDataRequestEvent.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/OutputDataRequestEvent.java
@@ -1,6 +1,6 @@
package org.gcube.portlets.user.dataminermanager.client.events;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationId;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationId;
import com.google.gwt.event.shared.EventHandler;
import com.google.gwt.event.shared.GwtEvent;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/ResubmitComputationExecutionEvent.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/ResubmitComputationExecutionEvent.java
index 97fb10b..c353650 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/ResubmitComputationExecutionEvent.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/ResubmitComputationExecutionEvent.java
@@ -1,6 +1,6 @@
package org.gcube.portlets.user.dataminermanager.client.events;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationId;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationId;
import com.google.gwt.event.shared.EventHandler;
import com.google.gwt.event.shared.GwtEvent;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/ResubmitComputationExecutionRequestEvent.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/ResubmitComputationExecutionRequestEvent.java
index d5ebb37..9140e5f 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/ResubmitComputationExecutionRequestEvent.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/ResubmitComputationExecutionRequestEvent.java
@@ -1,6 +1,6 @@
package org.gcube.portlets.user.dataminermanager.client.events;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.ItemDescription;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.ItemDescription;
import com.google.gwt.event.shared.EventHandler;
import com.google.gwt.event.shared.GwtEvent;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/StartComputationExecutionEvent.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/StartComputationExecutionEvent.java
index 2dce888..8deb16b 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/StartComputationExecutionEvent.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/StartComputationExecutionEvent.java
@@ -1,6 +1,6 @@
package org.gcube.portlets.user.dataminermanager.client.events;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationId;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationId;
import com.google.gwt.event.shared.EventHandler;
import com.google.gwt.event.shared.GwtEvent;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/StartComputationExecutionRequestEvent.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/StartComputationExecutionRequestEvent.java
index b2d5d92..afd20f9 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/StartComputationExecutionRequestEvent.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/StartComputationExecutionRequestEvent.java
@@ -1,6 +1,6 @@
package org.gcube.portlets.user.dataminermanager.client.events;
-import org.gcube.portlets.user.dataminermanager.shared.process.Operator;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.Operator;
import com.google.gwt.event.shared.EventHandler;
import com.google.gwt.event.shared.GwtEvent;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/TabularFldChangeEvent.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/TabularFldChangeEvent.java
index 8afa9d4..b7f62c8 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/TabularFldChangeEvent.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/events/TabularFldChangeEvent.java
@@ -1,6 +1,6 @@
package org.gcube.portlets.user.dataminermanager.client.events;
-import org.gcube.portlets.user.dataminermanager.shared.data.TableItemSimple;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.TableItemSimple;
import com.google.gwt.event.shared.EventHandler;
import com.google.gwt.event.shared.GwtEvent;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ComputationExecutionPanel.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ComputationExecutionPanel.java
index 512d8ad..bb51a6e 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ComputationExecutionPanel.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ComputationExecutionPanel.java
@@ -8,7 +8,7 @@ import org.gcube.portlets.user.dataminermanager.client.common.EventBusProvider;
import org.gcube.portlets.user.dataminermanager.client.events.ResubmitComputationExecutionEvent;
import org.gcube.portlets.user.dataminermanager.client.events.StartComputationExecutionEvent;
import org.gcube.portlets.user.dataminermanager.client.events.StartComputationExecutionRequestEvent;
-import org.gcube.portlets.user.dataminermanager.shared.process.Operator;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.Operator;
import com.allen_sauer.gwt.log.client.Log;
import com.sencha.gxt.core.client.dom.ScrollSupport.ScrollMode;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ComputationOutputPanel.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ComputationOutputPanel.java
index 6ce49f7..85be804 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ComputationOutputPanel.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ComputationOutputPanel.java
@@ -13,14 +13,14 @@ import org.gcube.portlets.user.dataminermanager.client.util.UtilsGXT3;
import org.gcube.portlets.user.dataminermanager.client.widgets.FileViewer;
import org.gcube.portlets.user.dataminermanager.client.widgets.ImageViewer;
import org.gcube.portlets.user.dataminermanager.client.widgets.ResourceViewer;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationId;
-import org.gcube.portlets.user.dataminermanager.shared.data.output.FileResource;
-import org.gcube.portlets.user.dataminermanager.shared.data.output.ImageResource;
-import org.gcube.portlets.user.dataminermanager.shared.data.output.MapResource;
-import org.gcube.portlets.user.dataminermanager.shared.data.output.ObjectResource;
-import org.gcube.portlets.user.dataminermanager.shared.data.output.Resource;
-import org.gcube.portlets.user.dataminermanager.shared.data.output.Resource.ResourceType;
-import org.gcube.portlets.user.dataminermanager.shared.data.output.TableResource;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationId;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.output.FileResource;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.output.ImageResource;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.output.MapResource;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.output.ObjectResource;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.output.Resource;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.output.Resource.ResourceType;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.output.TableResource;
import com.allen_sauer.gwt.log.client.Log;
import com.google.gwt.core.client.GWT;
@@ -143,8 +143,6 @@ public class ComputationOutputPanel extends SimpleContainer {
v.add(getMultipleOutput(mapResource), new VerticalLayoutData(1,
-1, new Margins(0)));
break;
- case ERROR:
- break;
case OBJECT:
break;
default:
@@ -227,8 +225,6 @@ public class ComputationOutputPanel extends SimpleContainer {
break;
case MAP:
break;
- case ERROR:
- break;
default:
break;
}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ComputationPanel.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ComputationPanel.java
index 6482625..9d595ae 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ComputationPanel.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ComputationPanel.java
@@ -5,7 +5,7 @@ import org.gcube.portlets.user.dataminermanager.client.events.ComputationReadyEv
import org.gcube.portlets.user.dataminermanager.client.events.ComputationReadyEvent.ComputationReadyEventHandler;
import org.gcube.portlets.user.dataminermanager.client.events.ComputationReadyEvent.HasComputationReadyEventHandler;
import org.gcube.portlets.user.dataminermanager.client.experiments.ComputationParametersPanel.ComputationParametersPanelHandler;
-import org.gcube.portlets.user.dataminermanager.shared.process.Operator;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.Operator;
import com.google.gwt.event.shared.HandlerRegistration;
import com.google.gwt.user.client.ui.HTML;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ComputationParametersPanel.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ComputationParametersPanel.java
index 2846edf..5e1cf5b 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ComputationParametersPanel.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ComputationParametersPanel.java
@@ -20,11 +20,11 @@ import org.gcube.portlets.user.dataminermanager.client.rpc.DataMinerPortletServi
import org.gcube.portlets.user.dataminermanager.client.util.UtilsGXT3;
import org.gcube.portlets.user.dataminermanager.shared.Constants;
import org.gcube.portlets.user.dataminermanager.shared.exception.SessionExpiredServiceException;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ColumnListParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ColumnParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ParameterType;
-import org.gcube.portlets.user.dataminermanager.shared.process.Operator;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ColumnListParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ColumnParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ParameterType;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.Operator;
import com.allen_sauer.gwt.log.client.Log;
import com.google.gwt.core.client.GWT;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ComputationStatusPanel.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ComputationStatusPanel.java
index 1019857..7af9049 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ComputationStatusPanel.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ComputationStatusPanel.java
@@ -11,9 +11,9 @@ import org.gcube.portlets.user.dataminermanager.client.events.CancelComputationE
import org.gcube.portlets.user.dataminermanager.client.rpc.DataMinerPortletServiceAsync;
import org.gcube.portlets.user.dataminermanager.client.util.UtilsGXT3;
import org.gcube.portlets.user.dataminermanager.shared.Constants;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationId;
-import org.gcube.portlets.user.dataminermanager.shared.process.ComputationStatus;
-import org.gcube.portlets.user.dataminermanager.shared.process.ComputationStatus.Status;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationId;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.ComputationStatus;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.ComputationStatus.Status;
import com.allen_sauer.gwt.log.client.Log;
import com.google.gwt.dom.client.Style.Unit;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/EquivalentRequestDialog.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/EquivalentRequestDialog.java
index 1363265..f67927e 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/EquivalentRequestDialog.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/EquivalentRequestDialog.java
@@ -1,6 +1,6 @@
package org.gcube.portlets.user.dataminermanager.client.experiments;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationId;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationId;
import com.allen_sauer.gwt.log.client.Log;
import com.sencha.gxt.widget.core.client.Dialog;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ExperimentPanel.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ExperimentPanel.java
index 565b32c..10b7a02 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ExperimentPanel.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/ExperimentPanel.java
@@ -1,6 +1,6 @@
package org.gcube.portlets.user.dataminermanager.client.experiments;
-import org.gcube.portlets.user.dataminermanager.shared.process.Operator;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.Operator;
import com.sencha.gxt.core.client.util.Margins;
import com.sencha.gxt.widget.core.client.container.BorderLayoutContainer;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/OperatorCategoryPanel.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/OperatorCategoryPanel.java
index 0625983..45b2809 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/OperatorCategoryPanel.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/OperatorCategoryPanel.java
@@ -6,8 +6,8 @@ package org.gcube.portlets.user.dataminermanager.client.experiments;
import java.util.ArrayList;
import java.util.List;
-import org.gcube.portlets.user.dataminermanager.shared.process.Operator;
-import org.gcube.portlets.user.dataminermanager.shared.process.OperatorCategory;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.Operator;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.OperatorCategory;
import com.google.gwt.core.client.GWT;
import com.google.gwt.event.dom.client.ClickEvent;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/OperatorPanel.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/OperatorPanel.java
index ef9554d..1daff34 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/OperatorPanel.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/OperatorPanel.java
@@ -1,6 +1,6 @@
package org.gcube.portlets.user.dataminermanager.client.experiments;
-import org.gcube.portlets.user.dataminermanager.shared.process.Operator;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.Operator;
import com.google.gwt.core.client.GWT;
import com.google.gwt.event.dom.client.ClickEvent;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/OperatorsPanel.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/OperatorsPanel.java
index 2a66770..10dca07 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/OperatorsPanel.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/OperatorsPanel.java
@@ -14,9 +14,9 @@ import org.gcube.portlets.user.dataminermanager.client.events.OperatorsClassific
import org.gcube.portlets.user.dataminermanager.client.events.OperatorsClassificationRequestEvent;
import org.gcube.portlets.user.dataminermanager.client.type.OperatorsClassificationRequestType;
import org.gcube.portlets.user.dataminermanager.shared.Constants;
-import org.gcube.portlets.user.dataminermanager.shared.process.Operator;
-import org.gcube.portlets.user.dataminermanager.shared.process.OperatorCategory;
-import org.gcube.portlets.user.dataminermanager.shared.process.OperatorsClassification;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.Operator;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.OperatorCategory;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.OperatorsClassification;
import com.allen_sauer.gwt.log.client.Log;
import com.google.gwt.event.dom.client.KeyUpEvent;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/OperatorsPanelHandler.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/OperatorsPanelHandler.java
index 4d5bfd2..ea23809 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/OperatorsPanelHandler.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/OperatorsPanelHandler.java
@@ -3,7 +3,7 @@
*/
package org.gcube.portlets.user.dataminermanager.client.experiments;
-import org.gcube.portlets.user.dataminermanager.shared.process.Operator;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.Operator;
/**
*
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/WorkflowPanel.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/WorkflowPanel.java
index 83afe13..c5da816 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/WorkflowPanel.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/experiments/WorkflowPanel.java
@@ -7,7 +7,7 @@ import org.gcube.portlets.user.dataminermanager.client.DataMinerManager;
import org.gcube.portlets.user.dataminermanager.client.common.EventBusProvider;
import org.gcube.portlets.user.dataminermanager.client.events.ComputationReadyEvent;
import org.gcube.portlets.user.dataminermanager.client.events.ResubmitComputationExecutionEvent;
-import org.gcube.portlets.user.dataminermanager.shared.process.Operator;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.Operator;
import com.allen_sauer.gwt.log.client.Log;
import com.sencha.gxt.widget.core.client.TabItemConfig;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/AbstractFld.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/AbstractFld.java
index 669f2ee..6fc6ed7 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/AbstractFld.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/AbstractFld.java
@@ -3,7 +3,7 @@
*/
package org.gcube.portlets.user.dataminermanager.client.parametersfield;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
import com.google.gwt.user.client.ui.Widget;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/BooleanFld.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/BooleanFld.java
index ba61d00..927bc2c 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/BooleanFld.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/BooleanFld.java
@@ -3,8 +3,8 @@
*/
package org.gcube.portlets.user.dataminermanager.client.parametersfield;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ObjectParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ObjectParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
import com.google.gwt.user.client.ui.Widget;
import com.sencha.gxt.cell.core.client.form.ComboBoxCell.TriggerAction;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/ColumnFld.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/ColumnFld.java
index a9e1b39..a300015 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/ColumnFld.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/ColumnFld.java
@@ -8,10 +8,10 @@ import java.util.ArrayList;
import org.gcube.portlets.user.dataminermanager.client.events.TabularFldChangeEvent;
import org.gcube.portlets.user.dataminermanager.client.events.TabularFldChangeEvent.TabularFldChangeEventHandler;
import org.gcube.portlets.user.dataminermanager.client.properties.ColumnItemPropertiesCombo;
-import org.gcube.portlets.user.dataminermanager.shared.data.ColumnItem;
-import org.gcube.portlets.user.dataminermanager.shared.data.TableItemSimple;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ColumnParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.ColumnItem;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.TableItemSimple;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ColumnParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
import com.allen_sauer.gwt.log.client.Log;
import com.google.gwt.core.client.GWT;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/ColumnListFld.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/ColumnListFld.java
index d7bccff..aefbc48 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/ColumnListFld.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/ColumnListFld.java
@@ -9,10 +9,10 @@ import java.util.List;
import org.gcube.portlets.user.dataminermanager.client.events.TabularFldChangeEvent;
import org.gcube.portlets.user.dataminermanager.client.events.TabularFldChangeEvent.TabularFldChangeEventHandler;
import org.gcube.portlets.user.dataminermanager.client.properties.ColumnItemProperties;
-import org.gcube.portlets.user.dataminermanager.shared.data.ColumnItem;
-import org.gcube.portlets.user.dataminermanager.shared.data.TableItemSimple;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ColumnListParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.ColumnItem;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.TableItemSimple;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ColumnListParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
import com.google.gwt.cell.client.AbstractCell;
import com.google.gwt.core.client.GWT;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/DateFld.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/DateFld.java
index 4fa6473..489567f 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/DateFld.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/DateFld.java
@@ -5,8 +5,8 @@ package org.gcube.portlets.user.dataminermanager.client.parametersfield;
import java.util.Date;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.DateParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.DateParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
import com.allen_sauer.gwt.log.client.Log;
import com.google.gwt.i18n.client.DateTimeFormat;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/DoubleFld.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/DoubleFld.java
index 224e6c9..e7786c8 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/DoubleFld.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/DoubleFld.java
@@ -1,7 +1,7 @@
package org.gcube.portlets.user.dataminermanager.client.parametersfield;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ObjectParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ObjectParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
import com.google.gwt.user.client.ui.Widget;
import com.sencha.gxt.core.client.util.Margins;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/EnumFld.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/EnumFld.java
index 33fd2c7..4641acb 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/EnumFld.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/EnumFld.java
@@ -3,8 +3,8 @@
*/
package org.gcube.portlets.user.dataminermanager.client.parametersfield;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.EnumParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.EnumParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
import com.google.gwt.user.client.ui.Widget;
import com.sencha.gxt.cell.core.client.form.ComboBoxCell.TriggerAction;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/FileFld.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/FileFld.java
index 1d379c0..dd7114a 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/FileFld.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/FileFld.java
@@ -13,9 +13,9 @@ import org.gcube.portlets.user.dataminermanager.client.events.SessionExpiredEven
import org.gcube.portlets.user.dataminermanager.client.rpc.DataMinerPortletServiceAsync;
import org.gcube.portlets.user.dataminermanager.client.util.UtilsGXT3;
import org.gcube.portlets.user.dataminermanager.shared.exception.SessionExpiredServiceException;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.FileParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.ItemDescription;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.FileParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.ItemDescription;
import org.gcube.portlets.widgets.netcdfbasicwidgets.client.event.SelectVariableEvent;
import org.gcube.portlets.widgets.netcdfbasicwidgets.client.event.SelectVariableEvent.SelectVariableEventHandler;
import org.gcube.portlets.widgets.netcdfbasicwidgets.client.widgets.NetCDFPreviewDialog;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/FloatFld.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/FloatFld.java
index 6219be6..fb00c22 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/FloatFld.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/FloatFld.java
@@ -1,7 +1,7 @@
package org.gcube.portlets.user.dataminermanager.client.parametersfield;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ObjectParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ObjectParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
import com.google.gwt.user.client.ui.Widget;
import com.sencha.gxt.core.client.util.Margins;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/IntFld.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/IntFld.java
index ee94beb..ac58a14 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/IntFld.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/IntFld.java
@@ -1,7 +1,7 @@
package org.gcube.portlets.user.dataminermanager.client.parametersfield;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ObjectParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ObjectParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
import com.google.gwt.user.client.ui.Widget;
import com.sencha.gxt.core.client.util.Margins;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/ListIntFld.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/ListIntFld.java
index 3705182..971c860 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/ListIntFld.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/ListIntFld.java
@@ -7,9 +7,9 @@ import java.util.ArrayList;
import java.util.List;
import org.gcube.portlets.user.dataminermanager.client.DataMinerManager;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ListParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ObjectParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ListParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ObjectParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
import com.google.gwt.user.client.ui.Widget;
import com.sencha.gxt.core.client.util.Margins;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/ListStringFld.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/ListStringFld.java
index 00abe8e..7bf982c 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/ListStringFld.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/ListStringFld.java
@@ -6,9 +6,9 @@ package org.gcube.portlets.user.dataminermanager.client.parametersfield;
import java.util.ArrayList;
import java.util.List;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ListParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ObjectParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ListParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ObjectParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
import com.google.gwt.user.client.ui.Widget;
import com.sencha.gxt.core.client.util.Margins;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/OperatorFieldWidget.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/OperatorFieldWidget.java
index d5facfa..046cb7a 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/OperatorFieldWidget.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/OperatorFieldWidget.java
@@ -3,9 +3,9 @@
*/
package org.gcube.portlets.user.dataminermanager.client.parametersfield;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ListParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ObjectParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ListParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ObjectParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
import com.allen_sauer.gwt.log.client.Log;
import com.sencha.gxt.widget.core.client.form.FieldLabel;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/StringFld.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/StringFld.java
index cb98acf..fbb440d 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/StringFld.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/StringFld.java
@@ -3,8 +3,8 @@
*/
package org.gcube.portlets.user.dataminermanager.client.parametersfield;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ObjectParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ObjectParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
import com.allen_sauer.gwt.log.client.Log;
import com.google.gwt.user.client.ui.Widget;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/StringItem.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/StringItem.java
index 042dd7d..1422a03 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/StringItem.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/StringItem.java
@@ -1,7 +1,7 @@
package org.gcube.portlets.user.dataminermanager.client.parametersfield;
import org.gcube.portlets.user.dataminermanager.client.DataMinerManager;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ObjectParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ObjectParameter;
import com.sencha.gxt.core.client.util.Margins;
import com.sencha.gxt.widget.core.client.button.TextButton;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/TabItem.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/TabItem.java
index 7551bf8..3303472 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/TabItem.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/TabItem.java
@@ -9,10 +9,10 @@ import org.gcube.portlets.user.dataminermanager.client.common.EventBusProvider;
import org.gcube.portlets.user.dataminermanager.client.events.SessionExpiredEvent;
import org.gcube.portlets.user.dataminermanager.client.rpc.DataMinerPortletServiceAsync;
import org.gcube.portlets.user.dataminermanager.client.util.UtilsGXT3;
-import org.gcube.portlets.user.dataminermanager.shared.data.TableItemSimple;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.TableItemSimple;
import org.gcube.portlets.user.dataminermanager.shared.exception.SessionExpiredServiceException;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.TabularParameter;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.ItemDescription;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.TabularParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.ItemDescription;
import org.gcube.portlets.widgets.wsexplorer.client.notification.WorkspaceExplorerSelectNotification.WorskpaceExplorerSelectNotificationListener;
import org.gcube.portlets.widgets.wsexplorer.client.select.WorkspaceExplorerSelectDialog;
import org.gcube.portlets.widgets.wsexplorer.shared.Item;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/TabularFld.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/TabularFld.java
index 53f5c3a..9b79362 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/TabularFld.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/TabularFld.java
@@ -15,11 +15,11 @@ import org.gcube.portlets.user.dataminermanager.client.events.TabularFldChangeEv
import org.gcube.portlets.user.dataminermanager.client.events.TabularFldChangeEvent.TabularFldChangeEventHandler;
import org.gcube.portlets.user.dataminermanager.client.rpc.DataMinerPortletServiceAsync;
import org.gcube.portlets.user.dataminermanager.client.util.UtilsGXT3;
-import org.gcube.portlets.user.dataminermanager.shared.data.TableItemSimple;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.TableItemSimple;
import org.gcube.portlets.user.dataminermanager.shared.exception.SessionExpiredServiceException;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.TabularParameter;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.ItemDescription;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.TabularParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.ItemDescription;
import org.gcube.portlets.widgets.wsexplorer.client.notification.WorkspaceExplorerSelectNotification.WorskpaceExplorerSelectNotificationListener;
import org.gcube.portlets.widgets.wsexplorer.client.select.WorkspaceExplorerSelectDialog;
import org.gcube.portlets.widgets.wsexplorer.shared.Item;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/TabularListFld.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/TabularListFld.java
index 0ab8b7f..c33287c 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/TabularListFld.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/TabularListFld.java
@@ -6,9 +6,9 @@ package org.gcube.portlets.user.dataminermanager.client.parametersfield;
import java.util.ArrayList;
import java.util.List;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.TabularListParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.TabularParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.TabularListParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.TabularParameter;
import com.allen_sauer.gwt.log.client.Log;
import com.google.gwt.user.client.ui.Widget;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/TimeFld.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/TimeFld.java
index efb3b6b..4ef5f06 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/TimeFld.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/TimeFld.java
@@ -5,8 +5,8 @@ package org.gcube.portlets.user.dataminermanager.client.parametersfield;
import java.util.Date;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.TimeParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.TimeParameter;
import com.allen_sauer.gwt.log.client.Log;
import com.google.gwt.i18n.client.DateTimeFormat;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/WKTFld.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/WKTFld.java
index 60cfa9f..7424d7a 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/WKTFld.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/parametersfield/WKTFld.java
@@ -5,8 +5,8 @@ package org.gcube.portlets.user.dataminermanager.client.parametersfield;
import org.gcube.portlets.user.dataminermanager.client.DataMinerManager;
import org.gcube.portlets.user.dataminermanager.client.util.UtilsGXT3;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.WKTParameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.WKTParameter;
import org.gcube.portlets.widgets.openlayerbasicwidgets.client.event.SelectAreaDialogEvent;
import org.gcube.portlets.widgets.openlayerbasicwidgets.client.event.SelectAreaDialogEvent.SelectAreaDialogEventHandler;
import org.gcube.portlets.widgets.openlayerbasicwidgets.client.widgets.AreaSelectionDialog;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/properties/ColumnItemProperties.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/properties/ColumnItemProperties.java
index 896bd45..6453a49 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/properties/ColumnItemProperties.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/properties/ColumnItemProperties.java
@@ -1,7 +1,7 @@
package org.gcube.portlets.user.dataminermanager.client.properties;
-import org.gcube.portlets.user.dataminermanager.shared.data.ColumnItem;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.ColumnItem;
import com.google.gwt.editor.client.Editor.Path;
import com.sencha.gxt.core.client.ValueProvider;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/properties/ColumnItemPropertiesCombo.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/properties/ColumnItemPropertiesCombo.java
index 26b06bb..d3839e4 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/properties/ColumnItemPropertiesCombo.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/properties/ColumnItemPropertiesCombo.java
@@ -1,6 +1,6 @@
package org.gcube.portlets.user.dataminermanager.client.properties;
-import org.gcube.portlets.user.dataminermanager.shared.data.ColumnItem;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.ColumnItem;
import com.google.gwt.editor.client.Editor.Path;
import com.sencha.gxt.data.shared.LabelProvider;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/rpc/DataMinerPortletService.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/rpc/DataMinerPortletService.java
index b4be978..73cda34 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/rpc/DataMinerPortletService.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/rpc/DataMinerPortletService.java
@@ -2,18 +2,18 @@ package org.gcube.portlets.user.dataminermanager.client.rpc;
import java.util.List;
-import org.gcube.portlets.user.dataminermanager.shared.data.OutputData;
-import org.gcube.portlets.user.dataminermanager.shared.data.TableItemSimple;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationData;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationId;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.OutputData;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.TableItemSimple;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationData;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationId;
import org.gcube.portlets.user.dataminermanager.shared.exception.ServiceException;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
-import org.gcube.portlets.user.dataminermanager.shared.process.ComputationStatus;
-import org.gcube.portlets.user.dataminermanager.shared.process.Operator;
-import org.gcube.portlets.user.dataminermanager.shared.process.OperatorsClassification;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.ComputationStatus;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.Operator;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.OperatorsClassification;
import org.gcube.portlets.user.dataminermanager.shared.session.UserInfo;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.DataMinerWorkArea;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.ItemDescription;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.DataMinerWorkArea;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.ItemDescription;
import org.gcube.portlets.widgets.wsexplorer.shared.Item;
import com.google.gwt.user.client.rpc.RemoteService;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/rpc/DataMinerPortletServiceAsync.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/rpc/DataMinerPortletServiceAsync.java
index 1dce85e..b7ffc38 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/rpc/DataMinerPortletServiceAsync.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/rpc/DataMinerPortletServiceAsync.java
@@ -2,17 +2,17 @@ package org.gcube.portlets.user.dataminermanager.client.rpc;
import java.util.List;
-import org.gcube.portlets.user.dataminermanager.shared.data.OutputData;
-import org.gcube.portlets.user.dataminermanager.shared.data.TableItemSimple;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationData;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationId;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
-import org.gcube.portlets.user.dataminermanager.shared.process.ComputationStatus;
-import org.gcube.portlets.user.dataminermanager.shared.process.Operator;
-import org.gcube.portlets.user.dataminermanager.shared.process.OperatorsClassification;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.OutputData;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.TableItemSimple;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationData;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationId;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.ComputationStatus;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.Operator;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.OperatorsClassification;
import org.gcube.portlets.user.dataminermanager.shared.session.UserInfo;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.DataMinerWorkArea;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.ItemDescription;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.DataMinerWorkArea;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.ItemDescription;
import org.gcube.portlets.widgets.wsexplorer.shared.Item;
import com.google.gwt.core.client.GWT;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/widgets/FileViewer.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/widgets/FileViewer.java
index 7a39546..6d5e38e 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/widgets/FileViewer.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/widgets/FileViewer.java
@@ -1,8 +1,8 @@
package org.gcube.portlets.user.dataminermanager.client.widgets;
import org.gcube.portlets.user.dataminermanager.client.DataMinerManager;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationId;
-import org.gcube.portlets.user.dataminermanager.shared.data.output.FileResource;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationId;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.output.FileResource;
import org.gcube.portlets.widgets.netcdfbasicwidgets.client.event.SelectVariableEvent;
import org.gcube.portlets.widgets.netcdfbasicwidgets.client.event.SelectVariableEvent.SelectVariableEventHandler;
import org.gcube.portlets.widgets.netcdfbasicwidgets.client.widgets.NetCDFPreviewDialog;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/widgets/ImageViewer.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/widgets/ImageViewer.java
index 89d78ad..3687b4a 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/widgets/ImageViewer.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/widgets/ImageViewer.java
@@ -1,8 +1,8 @@
package org.gcube.portlets.user.dataminermanager.client.widgets;
import org.gcube.portlets.user.dataminermanager.client.DataMinerManager;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationId;
-import org.gcube.portlets.user.dataminermanager.shared.data.output.ImageResource;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationId;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.output.ImageResource;
import com.google.gwt.user.client.ui.Image;
import com.sencha.gxt.core.client.util.Margins;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/client/widgets/ResourceViewer.java b/src/main/java/org/gcube/portlets/user/dataminermanager/client/widgets/ResourceViewer.java
index 1ce9317..1d2afa3 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/client/widgets/ResourceViewer.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/client/widgets/ResourceViewer.java
@@ -6,8 +6,8 @@ package org.gcube.portlets.user.dataminermanager.client.widgets;
import java.util.Map;
import java.util.Map.Entry;
-import org.gcube.portlets.user.dataminermanager.shared.data.output.ObjectResource;
-import org.gcube.portlets.user.dataminermanager.shared.data.output.Resource;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.output.ObjectResource;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.output.Resource;
import com.sencha.gxt.widget.core.client.container.HtmlLayoutContainer;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/dataminermanager.gwt.xml b/src/main/java/org/gcube/portlets/user/dataminermanager/dataminermanager.gwt.xml
index 767eb08..2602154 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/dataminermanager.gwt.xml
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/dataminermanager.gwt.xml
@@ -6,27 +6,30 @@
-
-
+
+
+
-
+
-
+
+
+
+
-
+
-
-
+
+
@@ -34,22 +37,21 @@
-
+
-
-
+ /> -->
+
-
-
-
+
+
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/server/DataMinerManagerServiceImpl.java b/src/main/java/org/gcube/portlets/user/dataminermanager/server/DataMinerManagerServiceImpl.java
index e95ffe4..e93c783 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/server/DataMinerManagerServiceImpl.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/server/DataMinerManagerServiceImpl.java
@@ -7,23 +7,23 @@ import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import org.gcube.portlets.user.dataminermanager.client.rpc.DataMinerPortletService;
-import org.gcube.portlets.user.dataminermanager.server.dmservice.SClient;
+import org.gcube.data.analysis.dataminermanagercl.server.dmservice.SClient;
import org.gcube.portlets.user.dataminermanager.server.storage.StorageUtil;
import org.gcube.portlets.user.dataminermanager.server.util.DataMinerWorkAreaManager;
-import org.gcube.portlets.user.dataminermanager.server.util.ServiceCredentials;
+import org.gcube.data.analysis.dataminermanagercl.server.util.ServiceCredentials;
import org.gcube.portlets.user.dataminermanager.server.util.TableReader;
-import org.gcube.portlets.user.dataminermanager.shared.data.OutputData;
-import org.gcube.portlets.user.dataminermanager.shared.data.TableItemSimple;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationData;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationId;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.OutputData;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.TableItemSimple;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationData;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.computations.ComputationId;
import org.gcube.portlets.user.dataminermanager.shared.exception.ServiceException;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
-import org.gcube.portlets.user.dataminermanager.shared.process.ComputationStatus;
-import org.gcube.portlets.user.dataminermanager.shared.process.Operator;
-import org.gcube.portlets.user.dataminermanager.shared.process.OperatorsClassification;
+import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.ComputationStatus;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.Operator;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.OperatorsClassification;
import org.gcube.portlets.user.dataminermanager.shared.session.UserInfo;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.DataMinerWorkArea;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.ItemDescription;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.DataMinerWorkArea;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.ItemDescription;
//import org.gcube.portlets.user.tdw.server.datasource.DataSourceFactoryRegistry;
//import org.gcube.portlets.widgets.file_dw_import_wizard.server.file.TargetRegistry;
import org.gcube.portlets.widgets.wsexplorer.shared.Item;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/server/DescriptionRepository.java b/src/main/java/org/gcube/portlets/user/dataminermanager/server/DescriptionRepository.java
index c39566d..882a587 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/server/DescriptionRepository.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/server/DescriptionRepository.java
@@ -3,8 +3,8 @@ package org.gcube.portlets.user.dataminermanager.server;
import java.util.ArrayList;
import java.util.List;
-import org.gcube.portlets.user.dataminermanager.shared.process.Operator;
-import org.gcube.portlets.user.dataminermanager.shared.process.OperatorCategory;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.Operator;
+import org.gcube.data.analysis.dataminermanagercl.shared.process.OperatorCategory;
/**
*
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/server/DownloadFolderServlet.java b/src/main/java/org/gcube/portlets/user/dataminermanager/server/DownloadFolderServlet.java
index df6b853..1a4cec5 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/server/DownloadFolderServlet.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/server/DownloadFolderServlet.java
@@ -13,7 +13,7 @@ import javax.servlet.http.HttpSession;
import org.apache.commons.io.IOUtils;
import org.gcube.portlets.user.dataminermanager.server.storage.StorageUtil;
-import org.gcube.portlets.user.dataminermanager.server.util.ServiceCredentials;
+import org.gcube.data.analysis.dataminermanagercl.server.util.ServiceCredentials;
import org.gcube.portlets.user.dataminermanager.shared.Constants;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/server/SessionUtil.java b/src/main/java/org/gcube/portlets/user/dataminermanager/server/SessionUtil.java
index a66ca0f..34cfa7f 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/server/SessionUtil.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/server/SessionUtil.java
@@ -12,11 +12,11 @@ import org.apache.log4j.Logger;
import org.gcube.common.authorization.library.provider.SecurityTokenProvider;
import org.gcube.common.portal.PortalContext;
import org.gcube.common.scope.api.ScopeProvider;
-import org.gcube.portlets.user.dataminermanager.server.dmservice.SClient;
-import org.gcube.portlets.user.dataminermanager.server.dmservice.SClient4WPSBuilder;
-import org.gcube.portlets.user.dataminermanager.server.dmservice.SClientBuilder;
-import org.gcube.portlets.user.dataminermanager.server.dmservice.SClientDirector;
-import org.gcube.portlets.user.dataminermanager.server.util.ServiceCredentials;
+import org.gcube.data.analysis.dataminermanagercl.server.dmservice.SClient;
+import org.gcube.data.analysis.dataminermanagercl.server.dmservice.SClient4WPSBuilder;
+import org.gcube.data.analysis.dataminermanagercl.server.dmservice.SClientBuilder;
+import org.gcube.data.analysis.dataminermanagercl.server.dmservice.SClientDirector;
+import org.gcube.data.analysis.dataminermanagercl.server.util.ServiceCredentials;
import org.gcube.portlets.user.dataminermanager.shared.Constants;
import org.gcube.portlets.user.dataminermanager.shared.exception.ServiceException;
import org.gcube.vomanagement.usermanagement.impl.LiferayGroupManager;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/SClient.java b/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/SClient.java
deleted file mode 100644
index 6219a78..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/SClient.java
+++ /dev/null
@@ -1,60 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.server.dmservice;
-
-import java.io.Serializable;
-import java.util.List;
-import java.util.Map;
-
-import org.gcube.portlets.user.dataminermanager.shared.data.OutputData;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationData;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationId;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
-import org.gcube.portlets.user.dataminermanager.shared.process.ComputationStatus;
-import org.gcube.portlets.user.dataminermanager.shared.process.Operator;
-import org.gcube.portlets.user.dataminermanager.shared.process.OperatorsClassification;
-
-/**
- *
- * Client of service
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public abstract class SClient implements Serializable{
-
-
- private static final long serialVersionUID = 7087349607933493388L;
-
- public SClient() {
- super();
- }
-
- public abstract List getOperatorsClassifications()
- throws Exception;
-
- public abstract List getInputParameters(Operator operator)
- throws Exception;
-
- public abstract ComputationId startComputation(Operator operator)
- throws Exception;
-
- public abstract ComputationStatus getComputationStatus(
- ComputationId computationId) throws Exception;
-
- public abstract OutputData getOutputDataByComputationId(
- ComputationId computationId) throws Exception;
-
- public abstract ComputationData getComputationDataByComputationProperties(
- Map computationProperties) throws Exception;
-
- public abstract String cancelComputation(ComputationId computationId)
- throws Exception;
-
- public abstract ComputationId resubmitComputation(
- Map computationProperties) throws Exception;
-
- @Override
- public String toString() {
- return "SClient []";
- }
-}
\ No newline at end of file
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/SClient4WPS.java b/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/SClient4WPS.java
deleted file mode 100644
index f18f675..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/SClient4WPS.java
+++ /dev/null
@@ -1,1311 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.server.dmservice;
-
-import java.io.ByteArrayInputStream;
-import java.io.InputStream;
-import java.io.UnsupportedEncodingException;
-import java.math.BigInteger;
-import java.net.URL;
-import java.net.URLEncoder;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.Date;
-import java.util.HashMap;
-import java.util.LinkedHashMap;
-import java.util.List;
-import java.util.Map;
-
-import net.opengis.ows.x11.OperationDocument.Operation;
-import net.opengis.wps.x100.CapabilitiesDocument;
-import net.opengis.wps.x100.ComplexDataType;
-import net.opengis.wps.x100.ExecuteDocument;
-import net.opengis.wps.x100.ExecuteResponseDocument;
-import net.opengis.wps.x100.ExecuteResponseDocument.ExecuteResponse.ProcessOutputs;
-import net.opengis.wps.x100.InputDescriptionType;
-import net.opengis.wps.x100.InputType;
-import net.opengis.wps.x100.OutputDataType;
-import net.opengis.wps.x100.OutputDescriptionType;
-import net.opengis.wps.x100.ProcessBriefType;
-import net.opengis.wps.x100.ProcessDescriptionType;
-import net.opengis.wps.x100.ResponseDocumentType;
-import net.opengis.wps.x100.StatusType;
-import net.opengis.wps.x100.SupportedComplexDataInputType;
-import net.opengis.wps.x100.impl.ExecuteResponseDocumentImpl;
-
-import org.apache.xmlbeans.XmlString;
-import org.gcube.portlets.user.dataminermanager.server.dmservice.wps.ProcessInformations;
-import org.gcube.portlets.user.dataminermanager.server.dmservice.wps.ResponseWPS;
-import org.gcube.portlets.user.dataminermanager.server.dmservice.wps.SClient4WPSSession;
-import org.gcube.portlets.user.dataminermanager.server.dmservice.wps.WPS2DM;
-import org.gcube.portlets.user.dataminermanager.server.dmservice.wps.computationsvalue.ComputationValueBuilder;
-import org.gcube.portlets.user.dataminermanager.server.is.InformationSystemUtils;
-import org.gcube.portlets.user.dataminermanager.server.storage.StorageUtil;
-import org.gcube.portlets.user.dataminermanager.server.util.ServiceCredentials;
-import org.gcube.portlets.user.dataminermanager.shared.Constants;
-import org.gcube.portlets.user.dataminermanager.shared.data.OutputData;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationData;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationId;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationItemPropertiesValue;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationValue;
-import org.gcube.portlets.user.dataminermanager.shared.data.output.FileResource;
-import org.gcube.portlets.user.dataminermanager.shared.data.output.ImageResource;
-import org.gcube.portlets.user.dataminermanager.shared.data.output.MapResource;
-import org.gcube.portlets.user.dataminermanager.shared.data.output.ObjectResource;
-import org.gcube.portlets.user.dataminermanager.shared.data.output.Resource;
-import org.gcube.portlets.user.dataminermanager.shared.exception.ServiceException;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.FileParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ObjectParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.TabularListParameter;
-import org.gcube.portlets.user.dataminermanager.shared.process.ComputationStatus;
-import org.gcube.portlets.user.dataminermanager.shared.process.Operator;
-import org.gcube.portlets.user.dataminermanager.shared.process.OperatorCategory;
-import org.gcube.portlets.user.dataminermanager.shared.process.OperatorsClassification;
-import org.gcube.portlets.user.dataminermanager.shared.process.ComputationStatus.Status;
-import org.n52.wps.client.ExecuteRequestBuilder;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.w3c.dom.NamedNodeMap;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-/**
- * Client 4 WPS Service
- *
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class SClient4WPS extends SClient {
-
- private static final long serialVersionUID = 1909871837115147159L;
- private static Logger logger = LoggerFactory.getLogger(SClient4WPS.class);
- // private static final int OPERATOR_BRIEF_DESCRIPTION_MAX_LENGHT = 170;
- private static final String OTHERS = "OTHERS";
-
- private String wpsToken;
- private String wpsUser;
- // private String wpsServiceURL;
- private String wpsProcessingServlet;
- private String wpsCancelComputationServlet;
-
- private ProcessDescriptionType[] processesDescriptionType;
- private ProcessBriefType[] processesBriefs;
-
- private HashMap process;
- private HashMap runningProcess;
-
- private SClient4WPSSession wpsClient;
-
- /**
- *
- * @param serviceCredentials
- * sevice credentials
- * @throws ServiceException
- * ServiceException
- */
- public SClient4WPS(ServiceCredentials serviceCredentials) throws ServiceException {
- super();
- process = new HashMap<>();
- runningProcess = new HashMap<>();
- if (serviceCredentials == null) {
- logger.error("Error credetials are null!");
- throw new ServiceException("Error credetials are null!");
- } else {
- String token = serviceCredentials.getToken();
- if (token == null || token.isEmpty()) {
- logger.error("Error authorization token invalid: " + token);
- throw new ServiceException("Error authorization token invalid: " + token);
- } else {
- wpsToken = token;
- }
-
- String userName = serviceCredentials.getUserName();
- if (userName == null || userName.isEmpty()) {
- logger.error("Error invalid user name: " + userName);
- throw new ServiceException("Error invalid user name: " + userName);
- } else {
- wpsUser = userName;
- }
- List serviceAddress;
- try {
- serviceAddress = InformationSystemUtils.retrieveServiceAddress(Constants.DATAMINER_SERVICE_CATEGORY,
- Constants.DATA_MINER_SERVICE_NAME, serviceCredentials.getScope());
- } catch (Exception e) {
- logger.error("Error retrieving service address: " + e.getLocalizedMessage());
- e.printStackTrace();
- throw new ServiceException(e.getLocalizedMessage(), e);
- }
- logger.debug("Service Address retrieved:" + serviceAddress);
- if (serviceAddress == null || serviceAddress.size() < 1) {
- logger.error("No DataMiner service address available!");
- throw new ServiceException("No DataMiner service address available!");
- } else {
- logger.info("DataMiner service address found: " + serviceAddress.get(0));
- wpsProcessingServlet = serviceAddress.get(0);
-
- int wpsWebProcessingServiceIndex = wpsProcessingServlet.indexOf(Constants.WPSWebProcessingService);
- if (wpsWebProcessingServiceIndex > 0) {
- String wpsServiceUrl = wpsProcessingServlet.substring(0, wpsWebProcessingServiceIndex);
- wpsCancelComputationServlet = wpsServiceUrl + Constants.WPSCancelComputationServlet;
- logger.debug("Cancel computation servlet: " + wpsCancelComputationServlet);
-
- } else {
- logger.error("Cancel computation servlet not available!");
- throw new ServiceException("Cancel computation servlet not available!");
- }
-
- }
-
- }
-
- }
-
- private SClient4WPSSession createWPSClientSession() {
- if (wpsClient == null) {
- wpsClient = new SClient4WPSSession(wpsUser, wpsToken);
- logger.debug("Created StatWPSClientSession");
- return wpsClient;
- } else {
- logger.debug("Use already created StatWPSClientSession");
- return wpsClient;
- }
- }
-
- @Override
- public List getOperatorsClassifications() throws ServiceException {
-
- LinkedHashMap operatorsToCategoriesMap = new LinkedHashMap<>();
- LinkedHashMap> categoriesToOperatorsMap = new LinkedHashMap<>();
-
- requestCapability();
- if (processesBriefs == null || processesDescriptionType == null) {
- throw new ServiceException("Algorithms WPS not available!");
- }
-
- for (ProcessBriefType processBrief : processesBriefs) {
- String categoryTitle = processBrief.getTitle().getStringValue();
- String categoryName;
- if (categoryTitle == null || categoryTitle.isEmpty()) {
- categoryName = OTHERS;
- } else {
- String[] categorySplitted = categoryTitle.split(":");
- if (categorySplitted.length < 1) {
- categoryName = OTHERS;
- } else {
- categoryName = categorySplitted[0];
- }
- }
- operatorsToCategoriesMap.put(processBrief.getIdentifier().getStringValue(), categoryName);
- }
-
- String briefDescription;
- for (ProcessBriefType processDescriptionType : processesDescriptionType) {
- briefDescription = processDescriptionType.getAbstract().getStringValue();
-
- String categoryName = operatorsToCategoriesMap.get(processDescriptionType.getIdentifier().getStringValue());
- if (categoryName == null || categoryName.isEmpty()) {
- categoryName = OTHERS;
- }
-
- List listOperators = categoriesToOperatorsMap.get(categoryName);
- if (listOperators == null) {
- listOperators = new ArrayList<>();
- }
-
- listOperators.add(new Operator(processDescriptionType.getIdentifier().getStringValue(),
- processDescriptionType.getTitle().getStringValue(), briefDescription,
- processDescriptionType.getAbstract().getStringValue(), null));
-
- categoriesToOperatorsMap.put(categoryName, listOperators);
-
- }
-
- List categories = new ArrayList<>();
- List operators = new ArrayList<>();
-
- Comparator categoriesComparator = new Comparator() {
- public int compare(OperatorCategory c1, OperatorCategory c2) {
- return c1.getName().compareTo(c2.getName()); // use your logic
- }
- };
-
- Comparator operatorsComparator = new Comparator() {
- public int compare(Operator c1, Operator c2) {
- return c1.getName().compareTo(c2.getName()); // use your logic
- }
- };
-
- for (String categoryName : categoriesToOperatorsMap.keySet()) {
- OperatorCategory category = new OperatorCategory(categoryName, categoryName, categoryName);
- List listOperators = categoriesToOperatorsMap.get(categoryName);
- for (Operator operator : listOperators) {
- operator.setCategory(category);
- }
- Collections.sort(listOperators, operatorsComparator);
- category.setOperators(listOperators);
- operators.addAll(listOperators);
- categories.add(category);
- }
-
- Collections.sort(operators, operatorsComparator);
- Collections.sort(categories, categoriesComparator);
-
- List operatorsClass = new ArrayList<>();
-
- OperatorsClassification op = new OperatorsClassification(Constants.UserClassificationName, categories,
- operators);
-
- operatorsClass.add(op);
-
- // logger.debug("OperatorClass: " + operatorsClass);
- return operatorsClass;
- }
-
- private ProcessInformations describeProcess(String processId) throws ServiceException {
- return describeProcess(processId, null);
- }
-
- private ProcessInformations describeProcess(String processId, URL processDescriptionURL) throws ServiceException {
- if (process.containsKey(processId)) {
- return process.get(processId);
- }
-
- SClient4WPSSession wpsClient = null;
- try {
- wpsClient = createWPSClientSession();
-
- logger.debug("Describe Process WPS URL: " + wpsProcessingServlet);
- ProcessDescriptionType processDescription = null;
- for (int k = 0; k <= 3; k++) {
- try {
- processDescription = wpsClient.getProcessDescription(wpsProcessingServlet, processId);
- } catch (Throwable e) {
- logger.error("Error getProcessDescription for process " + processId + " with WPS URL: "
- + wpsProcessingServlet);
- if (k == 3)
- throw e;
- }
- if (processDescription != null)
- break;
- }
-
- ProcessInformations processInformations = new ProcessInformations(processDescription);
-
- if (processDescriptionURL != null)
- processDescription.set(XmlString.Factory.parse(processDescriptionURL));
-
- logger.debug("ProcessDescription: " + processDescription);
-
- InputDescriptionType[] inputList = processDescription.getDataInputs().getInputArray();
- logger.debug("WPSClient->Fetching Inputs");
- for (InputDescriptionType input : inputList) {
- logger.debug("WPSClient->Input: " + input);
- }
-
- OutputDescriptionType[] outputList = processDescription.getProcessOutputs().getOutputArray();
- logger.debug("WPSClient->Fetching Outputs");
- for (OutputDescriptionType output : outputList) {
- logger.debug("WPSClient->Output: " + output);
- }
-
- processInformations.setInputs(inputList);
- processInformations.setOutputs(outputList);
-
- process.put(processId, processInformations);
-
- return processInformations;
- } catch (Throwable e) {
- logger.error(e.getLocalizedMessage(),e);
- throw new ServiceException(e.getLocalizedMessage(), e);
- } finally {
- wpsClient.disconnect(wpsProcessingServlet);
- }
- }
-
- private void requestCapability() throws ServiceException {
- SClient4WPSSession wpsClient = null;
- processesDescriptionType = null;
- processesBriefs = null;
-
- try {
- wpsClient = createWPSClientSession();
-
- wpsClient.connect(wpsProcessingServlet);
-
- processesDescriptionType = wpsClient.getAllProcessDescriptions(wpsProcessingServlet);
-
- CapabilitiesDocument capabilitiesDocument = wpsClient.getWPSCaps(wpsProcessingServlet);
-
- Operation[] operations = capabilitiesDocument.getCapabilities().getOperationsMetadata().getOperationArray();
- for (Operation operation : operations) {
- operation.getDCPArray()[0].getHTTP().getPostArray()[0].setHref(wpsProcessingServlet + "?");
-
- }
-
- processesBriefs = capabilitiesDocument.getCapabilities().getProcessOfferings().getProcessArray();
- return;
-
- } catch (Throwable e) {
- logger.error("RequestCapability(): " + e.getLocalizedMessage());
- e.printStackTrace();
- throw new ServiceException(e.getLocalizedMessage(), e);
- } finally {
- if (wpsClient != null) {
- wpsClient.disconnect(wpsProcessingServlet);
- }
- }
-
- }
-
- private String executeProcessAsync(ExecuteRequestBuilder executeBuilder, ProcessDescriptionType processDescription)
- throws ServiceException {
- SClient4WPSSession wpsClient = null;
- try {
- try {
-
- OutputDescriptionType[] odts = processDescription.getProcessOutputs().getOutputArray();
- for (OutputDescriptionType odt : odts) {
- // executeBuilder.setMimeTypeForOutput("text/xml",
- // "result");
- if (odt.isSetComplexOutput())
- executeBuilder.setMimeTypeForOutput("text/xml", odt.getIdentifier().getStringValue());
- }
- } catch (Exception e) {
- logger.debug("Execute Process-> Warning, no xml structured objects will be provided: "
- + e.getLocalizedMessage());
- e.printStackTrace();
- }
- // executeBuilder.setSchemaForOutput("http://schemas.opengis.net/gml/3.1.1/base/feature.xsd",
- // "result");
-
- ExecuteDocument execute = executeBuilder.getExecute();
- execute.getExecute().setService("WPS");
- // System.out.println("RESPONSE
- // FORM:"+execute.getExecute().getResponseForm());
- wpsClient = createWPSClientSession();
- wpsClient.connect(wpsProcessingServlet);
- logger.debug("Sending: " + execute);
- if (execute.getExecute().getResponseForm() != null) {
- ResponseDocumentType documentType = execute.getExecute().getResponseForm().getResponseDocument();
- documentType.setStoreExecuteResponse(true);
- documentType.setStatus(true);
- documentType.setLineage(false);
- execute.getExecute().getResponseForm().setResponseDocument(documentType);
- }
- Object responseObject = wpsClient.execute(wpsProcessingServlet, execute);
- String processLocation = null;
- Date creationData = null;
- if (responseObject != null) {
- if (responseObject instanceof ExecuteResponseDocumentImpl) {
- ExecuteResponseDocumentImpl executeResponseDocumentImpl = ((ExecuteResponseDocumentImpl) responseObject);
- processLocation = executeResponseDocumentImpl.getExecuteResponse().getStatusLocation();
- creationData = executeResponseDocumentImpl.getExecuteResponse().getStatus().getCreationTime()
- .getTime();
- } else {
- throw new ServiceException("Invalid response from service, "
- + "response isn't instance of ExecuteResponseDocumentImpl, class is "
- + responseObject.getClass());
- }
- } else {
- throw new ServiceException("Invalid Response from service, " + responseObject);
- }
- logger.debug("Retrieved: [ProcessLocation=" + processLocation + ", CreationDate=" + creationData + "]");
- return processLocation;
-
- } catch (Throwable e) {
- logger.error("ExecuteProcessAsync: " + e.getLocalizedMessage());
- e.printStackTrace();
- throw new ServiceException(e.getLocalizedMessage(), e);
- } finally {
- try {
- if (wpsClient != null)
- wpsClient.disconnect(wpsProcessingServlet);
- } catch (Exception e) {
- logger.debug("Problems in wps disconnect! " + e.getLocalizedMessage());
- }
- }
- }
-
- private ProcessOutputs retrieveProcessResult(String processLocation) throws ServiceException {
- SClient4WPSSession wpsClient = null;
- try {
- logger.debug("RetrieveProcessResult: " + processLocation);
- wpsClient = createWPSClientSession();
- // wpsClient.connectForMonitoring(webProcessingService);
- // wpsClient.connect(url)
-
- Object responseObject = null;
- if (processLocation != null && processLocation.length() > 0)
- responseObject = wpsClient.executeViaGET(processLocation, "");
- else
- throw new ServiceException("Process Location is null!");
-
- logger.debug("Response:\n" + responseObject);
- return ((ExecuteResponseDocument) responseObject).getExecuteResponse().getProcessOutputs();
-
- } catch (Throwable e) {
- logger.debug("RetrieveProcessResult: " + e.getLocalizedMessage());
- e.printStackTrace();
- throw new ServiceException(e.getLocalizedMessage(), e);
- } finally {
- wpsClient.disconnect(wpsProcessingServlet);
- }
- }
-
- private static int calculateBBDimensions(String bbstring) {
- String[] bbinput = bbstring.split(",");
- int dimcounter = 0;
- try {
- for (int i = 0; i < bbinput.length; i++) {
- Double.parseDouble(bbinput[i]);
- dimcounter++;
- }
- } catch (Exception e) {
- logger.debug("Dimensions Count: " + dimcounter);
- }
- return dimcounter;
- }
-
- private static void addBoundingBoxInput(org.n52.wps.client.ExecuteRequestBuilder executeBuilder, String identifier,
- String BBstring) {
-
- ExecuteDocument executor = executeBuilder.getExecute();
- InputType input1 = executor.getExecute().getDataInputs().addNewInput();
- input1.addNewIdentifier().setStringValue(identifier);
-
- net.opengis.ows.x11.BoundingBoxType bbtype = input1.addNewData().addNewBoundingBoxData();
-
- // bboxInput=46,102,47,103,urn:ogc:def:crs:EPSG:6.6:4326,2
- String[] bbinput = BBstring.split(",");
- int dimensions = calculateBBDimensions(BBstring);
- List lc = new ArrayList();
- for (int i = 0; i < dimensions / 2; i++) {
- lc.add(bbinput[i]);
- }
- List uc = new ArrayList();
- for (int i = dimensions / 2; i < dimensions; i++) {
- uc.add(bbinput[i]);
- }
-
- bbtype.setLowerCorner(lc);
- bbtype.setUpperCorner(uc);
-
- // int crsidx = bbinput[dimensions].indexOf("crs:");
- String crs = bbinput[dimensions];
- /*
- * if (crsidx>=0) crs = bbinput[dimensions].substring(crsidx+4);
- */
- bbtype.setCrs(crs);
- bbtype.setDimensions(new BigInteger("" + dimensions / 2));
-
- }
-
- private static LinkedHashMap retrieveURLsFromWPSResponse(ComplexDataType cdt) {
- org.w3c.dom.Node node = cdt.getDomNode();
- LinkedHashMap urls = new LinkedHashMap<>();
- getURLFromXML(node, urls);
- for (String key : urls.keySet()) {
- logger.debug("ResponseWPS Map: " + key + "-->" + urls.get(key));
- }
- return urls;
- }
-
- /*
- * private static String getExceptionText(String exceptionText) { try {
- * String excText = "ExceptionText>"; int idx =
- * exceptionText.indexOf(excText); if (idx >= 0) { String exception =
- * exceptionText.substring(idx + excText.length()); exception =
- * exception.substring(0, exception.indexOf("")); exception = exception
- * .replace("<", "") .replace(">", "") .replace("/", " ") .replace("\\",
- * " ") .replaceAll( "[\\]\\[!\"#$%&'\\(\\)*+/:;<=>?@\\^_`{\\|}~-]",
- * "_").trim(); exception = exception.replaceAll("[ ]+", " "); if
- * (exception.length() > 200) exception = exception.substring(0, 200) +
- * "..."; return exception; } else return "Process error in WPS Execution";
- * } catch (Exception e) { e.printStackTrace(); return
- * "Backend error in WPS Execution"; } }
- */
-
- private static void getURLFromXML(org.w3c.dom.Node node, ResponseWPS responseWPS) {
- if (node == null)
- return;
-
- logger.debug("Node Name: " + node.getNodeName());
- if (node.getNodeName() == null) {
- return;
- }
-
- if (node.getFirstChild() != null) {
- logger.debug("Node Value: " + node.getFirstChild().getNodeValue());
- } else {
- logger.debug("FirstChild is NULL");
- return;
- }
-
- String text;
- switch (node.getNodeName()) {
- case "d4science:Data":
- text = node.getFirstChild().getNodeValue();
- responseWPS.setData(text);
- break;
- case "d4science:Description":
- text = node.getFirstChild().getNodeValue();
- responseWPS.setDescription(text);
- break;
- case "d4science:MimeType":
- text = node.getFirstChild().getNodeValue();
- responseWPS.setMimeType(text);
- break;
- default:
- break;
- }
- /* logger.debug("ResponseWPS:"+responseWPS); */
-
- }
-
- private static void getURLFromXML(org.w3c.dom.Node node, LinkedHashMap urls) {
- if (node == null)
- return;
-
- logger.debug("Node Name: " + node.getNodeName());
-
- if (node.getNodeName() == null) {
- return;
- }
-
- ResponseWPS responseWPS = null;
- NodeList listnodes = node.getChildNodes();
- int nChildren = listnodes.getLength();
-
- switch (node.getNodeName()) {
- case "ogr:Result":
- NamedNodeMap attrs = node.getAttributes();
- Node n = attrs.getNamedItem("fid");
- String key = n.getNodeValue();
- responseWPS = new ResponseWPS();
- urls.put(key, responseWPS);
- if (nChildren == 0) {
-
- } else {
- for (int i = 0; i < nChildren; i++) {
- getURLFromXML(listnodes.item(i), responseWPS);
-
- }
- }
- break;
- default:
- if (nChildren == 0) {
-
- } else {
- for (int i = 0; i < nChildren; i++) {
- getURLFromXML(listnodes.item(i), urls);
-
- }
- }
- break;
-
- }
-
- /*
- *
- * NodeList listnodes = node.getChildNodes(); int nChildren =
- * listnodes.getLength();
- *
- * if (nChildren == 0) { String text = node.getNodeValue(); if (text !=
- * null && (text.startsWith("https:") || text.startsWith("http:") ||
- * text.startsWith("ftp:") || text.startsWith("smp:") || text
- * .startsWith("file:"))) urls.add(text.trim()); else if (text != null
- * && text.trim().length() > 0) urls.add(text.trim()); } else { for (int
- * i = 0; i < nChildren; i++) { List childrenurls =
- * getURLFromXML(listnodes.item(i)); urls.addAll(childrenurls);
- *
- * } } return urls;
- */
- }
-
- // TODO
- @Override
- public List getInputParameters(Operator operator) throws ServiceException {
- try {
- logger.debug("Input Parameters of algorithm " + operator.getId());
-
- ProcessInformations processInformations;
- try {
- processInformations = describeProcess(operator.getId());
- } catch (Throwable e) {
- logger.error("GetParameters: " + e.getLocalizedMessage());
- e.printStackTrace();
- throw new ServiceException(e.getLocalizedMessage());
- }
-
- logger.debug("ProcessInformation: " + processInformations);
-
- List parameters = new ArrayList<>();
-
- Parameter inputParameter;
- for (InputDescriptionType inputDesc : processInformations.getInputs()) {
- inputParameter = WPS2DM.convert2DMType(inputDesc);
- logger.debug("InputParameter: " + inputParameter);
- parameters.add(inputParameter);
- }
-
- logger.debug("Parameters: " + parameters);
- return parameters;
-
- } catch (Throwable e) {
- logger.error("Error in getInputParameters: " + e.getLocalizedMessage(), e);
- throw new ServiceException(e.getLocalizedMessage());
- }
-
- }
-
- @Override
- public ComputationId startComputation(Operator operator) throws ServiceException {
- ProcessInformations processInformations;
- try {
- processInformations = describeProcess(operator.getId());
- } catch (Throwable e) {
- logger.error("GetParameters: " + e.getLocalizedMessage());
- e.printStackTrace();
- throw new ServiceException(e.getLocalizedMessage(), e);
- }
-
- LinkedHashMap inputParameters = new LinkedHashMap<>();
-
- Parameter inputParameter;
- for (InputDescriptionType inputDesc : processInformations.getInputs()) {
- inputParameter = WPS2DM.convert2DMType(inputDesc);
- logger.debug("InputParameter: " + inputParameter);
- inputParameters.put(inputParameter.getName(), inputParameter);
- }
-
- List params = operator.getOperatorParameters();
- Map userInputs = new LinkedHashMap<>();
- for (Parameter parm : params) {
- userInputs.put(parm.getName(), parm.getValue());
- logger.debug("UserInputs[key=" + parm.getName() + ", value=" + parm.getValue() + "]");
- }
-
- LinkedHashMap equivalentRequestMap = new LinkedHashMap<>();
- String processUrl = compute(processInformations, userInputs, inputParameters, equivalentRequestMap);
- logger.debug("Stated Computation ProcessLocation:" + processUrl);
-
- int idIndex = processUrl.lastIndexOf("?id=");
- String id;
- if (idIndex > -1) {
- id = processUrl.substring(idIndex + 4, processUrl.length());
- } else {
- logger.error("Invalid processLocation: " + processUrl);
- throw new ServiceException("Invalid processLocation: " + processUrl);
- }
-
- String equivalentRequest = extractEquivalentRequestForComputation(operator, equivalentRequestMap);
-
- ComputationId computationId = new ComputationId(id, processUrl, operator.getId(), operator.getName(),
- equivalentRequest);
- logger.debug("ComputationId: " + computationId);
-
- runningProcess.put(computationId, processInformations);
-
- return computationId;
- }
-
- private String extractEquivalentRequestForComputation(Operator operator,
- LinkedHashMap equivalentRequestMap) {
- String equivalentRequest = wpsProcessingServlet + "?" + "request=Execute&service=WPS&Version=1.0.0&gcube-token="
- + wpsToken + "&lang=en-US&Identifier=" + operator.getId() + "&DataInputs=";
-
- for (String key : equivalentRequestMap.keySet()) {
- String keyEncoded = "";
- try {
- keyEncoded = URLEncoder.encode(key, "UTF-8");
- } catch (UnsupportedEncodingException e) {
- logger.error("Error in equivalent request creation: Unsupported Encoding for parameter=" + key, e);
- break;
- }
-
- String valueEncoded = "";
- try {
- valueEncoded = URLEncoder.encode(equivalentRequestMap.get(key), "UTF-8");
- } catch (UnsupportedEncodingException e) {
- logger.error("Error in equivalent request creation: Unsupported Encoding for value="
- + equivalentRequestMap.get(key) + " of parameter=" + key, e);
- break;
- }
- equivalentRequest = equivalentRequest + keyEncoded + "=" + valueEncoded + ";";
- }
-
- return equivalentRequest;
- }
-
- private String compute(ProcessInformations processInformations, Map userInputs,
- Map inputParameters, LinkedHashMap equivalentRequestMap)
- throws ServiceException {
- try {
- // setup the inputs
- org.n52.wps.client.ExecuteRequestBuilder executeBuilder = new org.n52.wps.client.ExecuteRequestBuilder(
- processInformations.getProcessDescription());
- for (InputDescriptionType input : processInformations.getInputs()) {
- String value = userInputs.get(input.getIdentifier().getStringValue());
- if (value != null && value.trim().length() > 0) {
- if (input.isSetLiteralData()) {
- logger.debug(
- "Configuring Literal: " + input.getIdentifier().getStringValue() + " to: " + value);
- equivalentRequestMap.put(input.getIdentifier().getStringValue(), value);
- executeBuilder.addLiteralData(input.getIdentifier().getStringValue(), value);
-
- } else if (input.isSetBoundingBoxData()) {
- logger.debug("Configuring Bounding Box: " + input.getIdentifier().getStringValue() + " to: "
- + value);
- equivalentRequestMap.put(input.getIdentifier().getStringValue(), value);
- addBoundingBoxInput(executeBuilder, input.getIdentifier().getStringValue(), value);
-
- } else {
- if (input.isSetComplexData()) {
- logger.debug(
- "Configuring Complex: " + input.getIdentifier().getStringValue() + " to: " + value);
- SupportedComplexDataInputType complex = input.getComplexData();
- Parameter par = inputParameters.get(input.getIdentifier().getStringValue());
-
- String publicLink;
- if (par instanceof TabularListParameter) {
- // TabularListParameter tabularListParameter =
- // ((TabularListParameter) par);
- InputStream tablesStream = new ByteArrayInputStream(value.getBytes());
- publicLink = StorageUtil.saveOnStorageInTemporalFile(tablesStream);
- } else {
- publicLink = value;
- }
- equivalentRequestMap.put(input.getIdentifier().getStringValue(), value);
- executeBuilder.addComplexDataReference(input.getIdentifier().getStringValue(), publicLink,
- complex.getDefault().getFormat().getSchema(),
- complex.getDefault().getFormat().getEncoding(),
- complex.getDefault().getFormat().getMimeType());
-
- } else {
- logger.error("This input parameter type is not supported by client library: " + input);
- throw new ServiceException(
- "This input parameter is not supported by client library: " + input);
- }
-
- }
- }
- }
-
- // Submit the execution
- String statusLocation = executeProcessAsync(executeBuilder, processInformations.getProcessDescription());
- logger.debug("Starting Process: " + statusLocation);
- return statusLocation;
-
- } catch (Throwable e) {
- logger.error(e.getLocalizedMessage(),e);
- throw new ServiceException(e.getLocalizedMessage(), e);
- }
- }
-
- @Override
- public ComputationStatus getComputationStatus(ComputationId computationId) throws ServiceException {
- SClient4WPSSession wpsClient = null;
- try {
- logger.debug("GetComputationStatus(): ComputationId=" + computationId);
- wpsClient = createWPSClientSession();
- wpsClient.connectForMonitoring(wpsProcessingServlet);
-
- Object responseObject = null;
- if (computationId == null || computationId.getUrlId() == null || computationId.getUrlId().isEmpty()) {
- throw new ServiceException("Process Location is null!");
- } else {
- ComputationStatus computationStatus = null;
- try {
-
- responseObject = wpsClient.executeViaGET(computationId.getUrlId(), "");
-
- logger.debug("ComputationStatus ResponseObject: " + responseObject);
-
- if (responseObject instanceof ExecuteResponseDocumentImpl) {
- if (((ExecuteResponseDocumentImpl) responseObject).getExecuteResponse() == null) {
- logger.debug("WPS FAILURE: ExecuteResponse is null");
-
- computationStatus = new ComputationStatus(Status.FAILED, 100f);
-
- } else {
- StatusType statusType = ((ExecuteResponseDocumentImpl) responseObject).getExecuteResponse()
- .getStatus();
- if (statusType == null) {
- logger.debug("WPS FAILURE: Status Type is null");
- computationStatus = null;
- } else {
-
- String failure = statusType.getProcessFailed() == null ? null
- : statusType.getProcessFailed().getExceptionReport().toString();
- if ((failure != null && !failure.isEmpty())) {
- logger.debug("WPS FAILURE: " + failure);
- computationStatus = new ComputationStatus(new ServiceException(failure));
- } else {
- String paused = statusType.getProcessPaused() == null ? null
- : statusType.getProcessPaused().getStringValue();
- if (paused != null && !paused.isEmpty()) {
- logger.debug("WPS PAUSED: " + paused);
- computationStatus = new ComputationStatus(new ServiceException(paused));
- } else {
- String success = statusType.getProcessSucceeded() == null ? null
- : statusType.getProcessSucceeded();
-
- if (success != null && !success.isEmpty()) {
- logger.debug("WPS SUCCESS");
- computationStatus = new ComputationStatus(Status.COMPLETE, 100f);
- } else {
- String accepted = statusType.getProcessAccepted() == null ? null
- : statusType.getProcessAccepted();
- if (accepted != null && !accepted.isEmpty()) {
- logger.debug("WPS ACCEPTED");
- computationStatus = new ComputationStatus(Status.ACCEPTED, 0f);
- } else {
- int status = statusType.getProcessStarted() == null ? -1
- : statusType.getProcessStarted().getPercentCompleted();
-
- if (status >= 0) {
- Float statusd = (float) status;
- try {
- statusd = Float.parseFloat(
- statusType.getProcessStarted().getStringValue());
- } catch (Exception e) {
- logger.debug(e.getLocalizedMessage());
- }
- logger.debug("WPS STATUS:" + statusd);
- computationStatus = new ComputationStatus(Status.RUNNING, statusd);
- } else {
- if (status == -1) {
- logger.debug("WPS STATUS: Computation cancelled, "
- + statusType.getProcessStarted());
- computationStatus = new ComputationStatus(Status.CANCELLED, -1);
-
- } else {
-
- logger.debug("WPS STATUS: Not Started, "
- + statusType.getProcessStarted());
- }
- }
- }
- }
- }
- }
- }
- }
- logger.debug("ComputationStatus: " + computationStatus);
- return computationStatus;
- } else {
- logger.error("Error in ResponceObject: " + responseObject);
- logger.error("WPS FAILURE: ");
- computationStatus = new ComputationStatus(Status.FAILED, 100f);
- return computationStatus;
- }
- } catch (Throwable e) {
- logger.error("WPS FAILURE: " + e.getLocalizedMessage());
- e.printStackTrace();
- computationStatus = new ComputationStatus(Status.FAILED, 100f);
- return computationStatus;
-
- }
- }
-
- } catch (Throwable e) {
- logger.error("MonitorProcess: " + e.getLocalizedMessage(),e);
- throw new ServiceException(e.getLocalizedMessage(), e);
- } finally {
- wpsClient.disconnect(wpsProcessingServlet);
- }
-
- }
-
- @Override
- public OutputData getOutputDataByComputationId(ComputationId computationId) throws ServiceException {
- LinkedHashMap resources = retrieveOutput(computationId);
- MapResource mapResource = new MapResource("mapResource", "Resources", "Resources", resources);
- OutputData outputData = new OutputData(computationId, mapResource);
-
- return outputData;
- }
-
- private LinkedHashMap retrieveOutput(ComputationId computationId) throws ServiceException {
- LinkedHashMap outputResource = new LinkedHashMap<>();
- LinkedHashMap outputParameters = new LinkedHashMap<>();
- ProcessInformations processInformations = runningProcess.get(computationId);
-
- Parameter outputParameter;
- if (processInformations != null && processInformations.getOutputs() != null) {
- for (OutputDescriptionType outputDesc : processInformations.getOutputs()) {
- outputParameter = WPS2DM.convert2DMType(outputDesc);
- logger.debug("OutputParameter: " + outputParameter);
- outputParameters.put(outputParameter.getName(), outputParameter);
- }
- }
-
- retrieveProcessOutput(computationId.getUrlId(), outputParameters, outputResource);
-
- return outputResource;
-
- }
-
- private void retrieveProcessOutput(String processLocation, Map outputParameters,
- Map outputResource) throws ServiceException {
- ProcessOutputs outs = retrieveProcessResult(processLocation);
- logger.debug("Process Executed");
- // retrieve the output objs
- if (outs == null)
- throw new ServiceException("Error during the execution of the WPS process: returned an empty document");
- else {
- OutputDataType[] outputData = outs.getOutputArray();
-
- for (OutputDataType out : outputData) {
- String outputID = out.getIdentifier().getStringValue();
- String value = "";
- if (out.getData().isSetLiteralData()) {
- value = out.getData().getLiteralData().getStringValue();
- Parameter paramLiteral = outputParameters.get(outputID);
- if (paramLiteral != null) {
- paramLiteral.setValue(value);
- logger.debug("Assigning value: " + value + " to output named: " + outputID);
- Resource resource = new ObjectResource(outputID, paramLiteral.getName(),
- paramLiteral.getDescription(), paramLiteral.getValue());
- outputResource.put(outputID, resource);
- }
- } else {
- if (out.getData().isSetComplexData()) {
- if (out.getReference() != null) {
- value = out.getReference().getHref();
- Parameter paramComplexData = outputParameters.get(outputID);
- if (paramComplexData != null) {
- paramComplexData.setValue(value);
- logger.debug("Assigning value: " + value + " to output named: " + outputID);
- Resource resource = new ObjectResource(outputID, paramComplexData.getName(),
- paramComplexData.getDescription(), paramComplexData.getValue());
- outputResource.put(outputID, resource);
- }
- } else
- // remove the element name, which is not useful
- outputParameters.remove(outputID);
-
- ComplexDataType cdt = out.getData().getComplexData();
- LinkedHashMap urls = retrieveURLsFromWPSResponse(cdt);
-
- for (String key : urls.keySet()) {
- logger.debug("Adding OBJ:" + key);
- ResponseWPS responseWPS = urls.get(key);
- ObjectParameter objP = new ObjectParameter(key, responseWPS.getDescription(),
- String.class.getName(), " ");
- objP.setValue(responseWPS.getData());
- logger.debug("ObjectParameter: " + objP);
- outputParameters.put(key, objP);
- if (responseWPS != null && responseWPS.getMimeType() != null) {
- Resource resource;
- switch (responseWPS.getMimeType()) {
- case "image/bmp":
- case "image/gif":
- case "image/jpeg":
- case "image/png":
- resource = new ImageResource(key, responseWPS.getDescription(),
- responseWPS.getDescription(), responseWPS.getData(),
- responseWPS.getMimeType());
- outputResource.put(key, resource);
- break;
- case "text/csv":
- if (responseWPS.getData() != null && !responseWPS.getData().isEmpty()) {
- if (responseWPS.getData().startsWith("http:")
- || responseWPS.getData().startsWith("https:")
- || responseWPS.getData().startsWith("smp:")) {
-
- Parameter complexParameter = outputParameters.get(outputID);
- if (complexParameter instanceof FileParameter) {
- FileParameter fileParameter = (FileParameter) complexParameter;
- if (fileParameter.isNetcdf()) {
- resource = new FileResource(key, responseWPS.getDescription(),
- responseWPS.getDescription(), responseWPS.getData(),
- responseWPS.getMimeType(), true);
- } else {
- resource = new FileResource(key, responseWPS.getDescription(),
- responseWPS.getDescription(), responseWPS.getData(),
- responseWPS.getMimeType(), false);
- }
- } else {
- resource = new FileResource(key, responseWPS.getDescription(),
- responseWPS.getDescription(), responseWPS.getData(),
- responseWPS.getMimeType(), false);
- }
- outputResource.put(key, resource);
- } else {
- resource = new ObjectResource(key, responseWPS.getDescription(),
- responseWPS.getDescription(), responseWPS.getData());
- outputResource.put(key, resource);
- }
- } else {
- resource = new ObjectResource(key, responseWPS.getDescription(),
- responseWPS.getDescription(), responseWPS.getData());
- outputResource.put(key, resource);
- }
-
- break;
- default:
- if (responseWPS.getData() != null && !responseWPS.getData().isEmpty()) {
- if (responseWPS.getData().startsWith("http:")
- || responseWPS.getData().startsWith("https:")
- || responseWPS.getData().startsWith("smp:")) {
- Parameter complexParameter = outputParameters.get(outputID);
- if (complexParameter instanceof FileParameter) {
- FileParameter fileParameter = (FileParameter) complexParameter;
- if (fileParameter.isNetcdf()) {
- resource = new FileResource(key, responseWPS.getDescription(),
- responseWPS.getDescription(), responseWPS.getData(),
- responseWPS.getMimeType(), true);
- } else {
- resource = new FileResource(key, responseWPS.getDescription(),
- responseWPS.getDescription(), responseWPS.getData(),
- responseWPS.getMimeType(), false);
- }
- } else {
- resource = new FileResource(key, responseWPS.getDescription(),
- responseWPS.getDescription(), responseWPS.getData(),
- responseWPS.getMimeType(), false);
- }
- outputResource.put(key, resource);
- } else {
- resource = new ObjectResource(key, responseWPS.getDescription(),
- responseWPS.getDescription(), responseWPS.getData());
- outputResource.put(key, resource);
- }
- } else {
- resource = new ObjectResource(key, responseWPS.getDescription(),
- responseWPS.getDescription(), responseWPS.getData());
- outputResource.put(key, resource);
- }
- break;
- }
-
- }
- }
- } else {
- value = out.getData().getLiteralData().getStringValue();
-
- }
- }
- }
- }
- }
-
- @Override
- public String cancelComputation(ComputationId computationId) throws ServiceException {
- SClient4WPSSession wpsClient = null;
- try {
- wpsClient = createWPSClientSession();
-
- String result = wpsClient.cancelComputation(wpsCancelComputationServlet, computationId.getId());
-
- return result;
-
- } catch (Throwable e) {
- logger.error(e.getLocalizedMessage(), e);
- throw new ServiceException(e.getLocalizedMessage(), e);
- } finally {
- if (wpsClient != null) {
- wpsClient.disconnect(wpsProcessingServlet);
- }
- }
-
- }
-
- @Override
- public ComputationId resubmitComputation(Map computationProperties) throws ServiceException {
- ProcessInformations processInformations;
- if (computationProperties == null || computationProperties.isEmpty()) {
- throw new ServiceException("Invalid computation properties: " + computationProperties);
- }
- try {
- processInformations = describeProcess(computationProperties.get("operator_id"));
- } catch (Throwable e) {
- logger.error("GetParameters: " + e.getLocalizedMessage());
- e.printStackTrace();
- throw new ServiceException(e.getLocalizedMessage(), e);
- }
-
- LinkedHashMap inputParameters = new LinkedHashMap<>();
-
- Parameter inputParameter;
- for (InputDescriptionType inputDesc : processInformations.getInputs()) {
- inputParameter = WPS2DM.convert2DMType(inputDesc);
- logger.debug("InputParameter: " + inputParameter);
- inputParameters.put(inputParameter.getName(), inputParameter);
- }
-
- Map userInputs = new LinkedHashMap<>();
- for (String key : computationProperties.keySet()) {
- if (key.startsWith("input")) {
- int inputSeparatorIndex = key.indexOf("_");
- String inputKey = key.substring(inputSeparatorIndex + 1);
- if (inputKey.compareToIgnoreCase("user.name") != 0 && inputKey.compareToIgnoreCase("scope") != 0) {
- userInputs.put(inputKey, computationProperties.get(key));
- logger.debug("UserInputs[key=" + inputKey + ", value=" + computationProperties.get(key) + "]");
- }
-
- }
- }
-
- if (userInputs.isEmpty()) {
- logger.error("Attention no inputs parameters retrieved for this computation: " + computationProperties);
- throw new ServiceException(
- "Attention no inputs parameters retrieved for this computation: " + computationProperties);
- }
-
- LinkedHashMap equivalentRequestMap = new LinkedHashMap<>();
- String processUrl = compute(processInformations, userInputs, inputParameters, equivalentRequestMap);
- logger.debug("Stated Computation ProcessLocation:" + processUrl);
-
- int idIndex = processUrl.lastIndexOf("?id=");
- String id;
- if (idIndex > -1) {
- id = processUrl.substring(idIndex + 4, processUrl.length());
- } else {
- logger.error("Invalid processLocation: " + processUrl);
- throw new ServiceException("Invalid processLocation: " + processUrl);
- }
-
- String equivalentRequest = extractEquivalentRequestForResubmit(computationProperties, equivalentRequestMap);
-
- ComputationId computationId = new ComputationId(id, processUrl, computationProperties.get("operator_id"),
- computationProperties.get("operator_name"), equivalentRequest);
- logger.debug("ComputationId: " + computationId);
-
- runningProcess.put(computationId, processInformations);
-
- return computationId;
- }
-
- private String extractEquivalentRequestForResubmit(Map computationProperties,
- LinkedHashMap equivalentRequestMap) {
- String equivalentRequest = wpsProcessingServlet + "?" + "request=Execute&service=WPS&Version=1.0.0&gcube-token="
- + wpsToken + "&lang=en-US&Identifier=" + computationProperties.get("operator_id") + "&DataInputs=";
-
- for (String key : equivalentRequestMap.keySet()) {
- String keyEncoded = "";
- try {
- keyEncoded = URLEncoder.encode(key, "UTF-8");
- } catch (UnsupportedEncodingException e) {
- logger.error("Error in equivalent request creation: Unsupported Encoding for parameter=" + key, e);
- break;
- }
-
- String valueEncoded = "";
- try {
- valueEncoded = URLEncoder.encode(equivalentRequestMap.get(key), "UTF-8");
- } catch (UnsupportedEncodingException e) {
- logger.error("Error in equivalent request creation: Unsupported Encoding for value="
- + equivalentRequestMap.get(key) + " of parameter=" + key, e);
- break;
- }
- equivalentRequest = equivalentRequest + keyEncoded + "=" + valueEncoded + ";";
- }
-
- return equivalentRequest;
- }
-
- @Override
- public ComputationData getComputationDataByComputationProperties(Map computationProperties)
- throws ServiceException {
- try {
- if (computationProperties == null || computationProperties.isEmpty()) {
- throw new Exception("Invalid computation properties: " + computationProperties);
- }
-
- String compId = computationProperties.get("computation_id");
-
- String operatorId = computationProperties.get("operator_id");
- String operatorName = computationProperties.get("operator_name");
- String operatorDescritpion = computationProperties.get("operator_description");
- String vre = computationProperties.get("VRE");
- String startDate = computationProperties.get("start_date");
- String endDate = computationProperties.get("end_date");
- String status = computationProperties.get("status");
- String executionType = computationProperties.get("execution_type");
-
- ComputationId computationId = new ComputationId();
- computationId.setId(compId);
- computationId.setOperatorId(operatorId);
- computationId.setOperatorName(operatorName);
-
- ArrayList inputParametersAsProperties = new ArrayList<>();
- ArrayList outputParametersAsProperties = new ArrayList<>();
-
- for (String key : computationProperties.keySet()) {
- if (key != null) {
- if (key.startsWith("input")) {
- int inputSeparatorIndex = key.indexOf("_");
- String inputKey = key.substring(inputSeparatorIndex + 1);
- if (inputKey.compareToIgnoreCase("user.name") != 0
- && inputKey.compareToIgnoreCase("scope") != 0) {
- String inputOrder = key.substring(5, inputSeparatorIndex);
- Integer order;
- try {
- order = Integer.parseInt(inputOrder);
- } catch (NumberFormatException e) {
- order = 0;
- }
- ComputationItemPropertiesValue inputProps = new ComputationItemPropertiesValue(order,
- inputKey, computationProperties.get(key));
- inputParametersAsProperties.add(inputProps);
-
- }
-
- } else {
- if (key.startsWith("output")) {
- int outputSeparatorIndex = key.indexOf("_");
- String outputKey = key.substring(outputSeparatorIndex + 1);
-
- String outputOrder = key.substring(6, outputSeparatorIndex);
- Integer order;
- try {
- order = Integer.parseInt(outputOrder);
- } catch (NumberFormatException e) {
- order = 0;
- }
- ComputationItemPropertiesValue outputProps = new ComputationItemPropertiesValue(order,
- outputKey, computationProperties.get(key));
-
- outputParametersAsProperties.add(outputProps);
-
- }
-
- }
-
- }
- }
-
- Collections.sort(inputParametersAsProperties);
- Collections.sort(outputParametersAsProperties);
-
- ComputationValueBuilder computationValueBuilder = new ComputationValueBuilder(inputParametersAsProperties);
- LinkedHashMap inputParameters = computationValueBuilder.create();
- computationValueBuilder = new ComputationValueBuilder(outputParametersAsProperties);
- LinkedHashMap outputParameters = computationValueBuilder.create();
-
- logger.debug("inputParameters: " + inputParameters);
- logger.debug("outputParameters: " + outputParameters);
-
- ComputationData computationData = new ComputationData(computationId, inputParameters, outputParameters,
- operatorDescritpion, startDate, endDate, status, executionType, vre);
-
- logger.debug("ComputationData: " + computationData);
- return computationData;
-
- } catch (ServiceException e) {
- logger.error("Error in getComutationDataByComputationProperties: " + e.getLocalizedMessage());
- e.printStackTrace();
- throw e;
- } catch (Throwable e) {
- logger.error("Error in getComutationDataByComputationProperties: " + e.getLocalizedMessage());
- e.printStackTrace();
- throw new ServiceException(e.getLocalizedMessage(), e);
-
- }
-
- }
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/SClient4WPSBuilder.java b/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/SClient4WPSBuilder.java
deleted file mode 100644
index 3c7723b..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/SClient4WPSBuilder.java
+++ /dev/null
@@ -1,40 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.server.dmservice;
-
-import org.gcube.portlets.user.dataminermanager.server.util.ServiceCredentials;
-import org.gcube.portlets.user.dataminermanager.shared.exception.ServiceException;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-/**
- * Builder of Client 4 WPS Service
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class SClient4WPSBuilder extends SClientBuilder {
- private static Logger logger = LoggerFactory
- .getLogger(SClient4WPSBuilder.class);
- private ServiceCredentials serviceCredendial;
-
- public SClient4WPSBuilder(ServiceCredentials serviceCredential) {
- this.serviceCredendial= serviceCredential;
-
- }
-
- @Override
- public void buildSClient() throws ServiceException {
- try {
- logger.debug("Build SC4WPS");
- logger.debug("ServiceCredential: " + serviceCredendial);
- SClient sClient = new SClient4WPS(serviceCredendial);
-
- sClientSpec.setSClient(sClient);
- } catch (Throwable e) {
- logger.error(e.getLocalizedMessage());
- e.printStackTrace();
- throw new ServiceException(e.getLocalizedMessage());
- }
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/SClientBuilder.java b/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/SClientBuilder.java
deleted file mode 100644
index e31bdd9..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/SClientBuilder.java
+++ /dev/null
@@ -1,26 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.server.dmservice;
-
-import org.gcube.portlets.user.dataminermanager.shared.exception.ServiceException;
-
-/**
- * Abstract class for build client of service
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public abstract class SClientBuilder {
- protected SClientSpec sClientSpec;
-
- public SClientSpec getSClientSpec() {
- return sClientSpec;
- }
-
- public void createSpec() {
- sClientSpec = new SClientSpec();
-
- }
-
- public abstract void buildSClient() throws ServiceException;
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/SClientDirector.java b/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/SClientDirector.java
deleted file mode 100644
index ee351b0..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/SClientDirector.java
+++ /dev/null
@@ -1,31 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.server.dmservice;
-
-import org.gcube.portlets.user.dataminermanager.shared.exception.ServiceException;
-
-
-/**
- * Director
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class SClientDirector {
- SClientBuilder sClientBuilder;
-
- public void setSClientBuilder(
- SClientBuilder sClientBuilder) {
- this.sClientBuilder = sClientBuilder;
- }
-
- public SClient getSClient() {
- return sClientBuilder.getSClientSpec().getSClient();
-
- }
-
- public void constructSClient() throws ServiceException {
- sClientBuilder.createSpec();
- sClientBuilder.buildSClient();
-
- }
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/SClientSpec.java b/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/SClientSpec.java
deleted file mode 100644
index 6961eb2..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/SClientSpec.java
+++ /dev/null
@@ -1,21 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.server.dmservice;
-
-/**
- * Specification
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class SClientSpec {
- private SClient sClient;
-
- public SClient getSClient() {
- return sClient;
- }
-
- public void setSClient(SClient sClient) {
- this.sClient = sClient;
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/wps/DClientDescribeProcessRequest.java b/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/wps/DClientDescribeProcessRequest.java
deleted file mode 100644
index cc46fa2..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/wps/DClientDescribeProcessRequest.java
+++ /dev/null
@@ -1,36 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.server.dmservice.wps;
-
-import org.n52.wps.client.AbstractClientGETRequest;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class DClientDescribeProcessRequest extends AbstractClientGETRequest {
-
- private static String IDENTIFIER_REQ_PARAM_NAME = "identifier";
- private static String REQUEST_REQ_PARAM_VALUE = "DescribeProcess";
-
- public DClientDescribeProcessRequest() {
- super();
- setRequestParamValue(REQUEST_REQ_PARAM_VALUE);
- }
-
- public void setIdentifier(String[] ids) {
- String idsString = "";
- for(int i = 0; i < ids.length; i++) {
- idsString = idsString + ids[i];
- if(i != ids.length -1) {
- idsString = idsString + ",";
- }
- }
- requestParams.put(IDENTIFIER_REQ_PARAM_NAME, idsString);
- }
-
- public boolean valid() {
- return true;
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/wps/ProcessInformations.java b/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/wps/ProcessInformations.java
deleted file mode 100644
index 77a1fdf..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/wps/ProcessInformations.java
+++ /dev/null
@@ -1,71 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.server.dmservice.wps;
-
-import java.io.Serializable;
-import java.util.Arrays;
-
-import net.opengis.wps.x100.InputDescriptionType;
-import net.opengis.wps.x100.OutputDescriptionType;
-import net.opengis.wps.x100.ProcessDescriptionType;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class ProcessInformations implements Serializable {
-
- private static final long serialVersionUID = 4729933672312944832L;
- private ProcessDescriptionType processDescription;
- private InputDescriptionType[] inputs;
- private OutputDescriptionType[] outputs;
-
- public ProcessInformations(ProcessDescriptionType processDescription) {
- super();
- this.processDescription = processDescription;
- this.inputs = new InputDescriptionType[0];
- this.outputs = new OutputDescriptionType[0];
- }
-
- public ProcessInformations(ProcessDescriptionType processDescription,
- InputDescriptionType[] inputs, OutputDescriptionType[] outputs) {
- super();
- this.processDescription = processDescription;
- this.inputs = inputs;
- this.outputs = outputs;
- }
-
- public ProcessDescriptionType getProcessDescription() {
- return processDescription;
- }
-
- public void setProcessDescription(
- ProcessDescriptionType processDescription) {
- this.processDescription = processDescription;
- }
-
- public InputDescriptionType[] getInputs() {
- return inputs;
- }
-
- public void setInputs(InputDescriptionType[] inputs) {
- this.inputs = inputs;
- }
-
- public OutputDescriptionType[] getOutputs() {
- return outputs;
- }
-
- public void setOutputs(OutputDescriptionType[] outputs) {
- this.outputs = outputs;
- }
-
- @Override
- public String toString() {
- return "ProcessInformations [processDescription="
- + processDescription + ", inputs="
- + Arrays.toString(inputs) + ", outputs="
- + Arrays.toString(outputs) + "]";
- }
-
-}
\ No newline at end of file
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/wps/ResponseWPS.java b/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/wps/ResponseWPS.java
deleted file mode 100644
index cf857d6..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/wps/ResponseWPS.java
+++ /dev/null
@@ -1,58 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.server.dmservice.wps;
-
-import java.io.Serializable;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class ResponseWPS implements Serializable {
- private static final long serialVersionUID = 3449817768583395068L;
- private String data;
- private String description;
- private String mimeType;
-
- public ResponseWPS() {
- super();
- }
-
- public ResponseWPS(String data, String description, String mimeType) {
- super();
- this.data = data;
- this.description = description;
- this.mimeType = mimeType;
- }
-
- public String getData() {
- return data;
- }
-
- public void setData(String data) {
- this.data = data;
- }
-
- public String getDescription() {
- return description;
- }
-
- public void setDescription(String description) {
- this.description = description;
- }
-
- public String getMimeType() {
- return mimeType;
- }
-
- public void setMimeType(String mimeType) {
- this.mimeType = mimeType;
- }
-
- @Override
- public String toString() {
- return "ResponseWPS [data=" + data + ", description=" + description
- + ", mimeType=" + mimeType + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/wps/SClient4WPSSession.java b/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/wps/SClient4WPSSession.java
deleted file mode 100644
index 8d2f4cc..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/wps/SClient4WPSSession.java
+++ /dev/null
@@ -1,753 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.server.dmservice.wps;
-
-import java.io.BufferedReader;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.InputStreamReader;
-import java.io.Serializable;
-import java.net.HttpURLConnection;
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.nio.charset.Charset;
-import java.nio.file.Files;
-import java.nio.file.Path;
-import java.nio.file.StandardOpenOption;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.zip.GZIPInputStream;
-
-import javax.xml.parsers.DocumentBuilderFactory;
-import javax.xml.parsers.ParserConfigurationException;
-
-import net.opengis.ows.x11.ExceptionReportDocument;
-import net.opengis.ows.x11.OperationDocument.Operation;
-import net.opengis.wps.x100.CapabilitiesDocument;
-import net.opengis.wps.x100.ExecuteDocument;
-import net.opengis.wps.x100.ExecuteResponseDocument;
-import net.opengis.wps.x100.ProcessBriefType;
-import net.opengis.wps.x100.ProcessDescriptionType;
-import net.opengis.wps.x100.ProcessDescriptionsDocument;
-
-import org.apache.commons.codec.binary.Base64;
-import org.apache.xmlbeans.XmlException;
-import org.apache.xmlbeans.XmlObject;
-import org.apache.xmlbeans.XmlOptions;
-import org.n52.wps.client.ClientCapabiltiesRequest;
-import org.n52.wps.client.WPSClientException;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.w3c.dom.Document;
-import org.w3c.dom.Node;
-import org.xml.sax.SAXException;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class SClient4WPSSession implements Serializable {
-
- private static final long serialVersionUID = -1387670579312851370L;
- private static Logger logger = LoggerFactory.getLogger(SClient4WPSSession.class);
- private static final String OGC_OWS_URI = "http://www.opengeospatial.net/ows";
- private static String SUPPORTED_VERSION = "1.0.0";
-
- // private static StatWPSClientSession session;
- private HashMap loggedServices;
- private XmlOptions options = null;
-
- // a Map of
- public HashMap processDescriptions;
- private String user;
- private String password;
-
- /**
- * Initializes a WPS client session.
- *
- * @param user
- * user
- * @param password
- * password
- */
- public SClient4WPSSession(String user, String password) {
- super();
- logger.debug("Create SClient4WPSSession: [user=" + user + ", password=" + password + "]");
- this.user = user;
- this.password = password;
- options = new XmlOptions();
- options.setLoadStripWhitespace();
- options.setLoadTrimTextBuffer();
- loggedServices = new HashMap();
- processDescriptions = new HashMap();
- }
-
- /**
- * Connects to a WPS and retrieves Capabilities plus puts all available
- * Descriptions into cache.
- *
- * @param url
- * the entry point for the service. This is used as id for
- * further identification of the service.
- * @return true, if connect succeeded, false else.
- * @throws WPSClientException
- * wps client exception
- */
-
- public boolean connect(String url) throws WPSClientException {
- logger.info("CONNECT: " + url);
- logger.debug("LoggedSevices: " + loggedServices.keySet());
- if (loggedServices.containsKey(url)) {
- logger.debug("Service already registered: " + url);
- return false;
- }
- logger.debug("Service not registered");
- CapabilitiesDocument capsDoc = retrieveCapsViaGET(url);
- if (capsDoc != null) {
- logger.debug("Adding caps to logged services " + url);
- loggedServices.put(url, capsDoc);
- logger.debug("Logged Services key: " + loggedServices.keySet());
- } else {
- logger.error("CapsDoc is null!");
- }
-
- ProcessDescriptionsDocument processDescs = describeAllProcesses(url);
- if (processDescs != null && capsDoc != null) {
- logger.debug("Adding processes descriptions to logged services " + url);
- processDescriptions.put(url, processDescs);
- logger.debug("ProcessDescriptions key: " + processDescriptions.keySet());
- return true;
-
- } else {
- logger.error("ProcessDescs is null!");
- }
-
- logger.warn("retrieving caps failed, caps are null");
- return false;
- }
-
- /**
- * Connects to a WPS and retrieves Capabilities plus puts all available
- * Descriptions into cache.
- *
- * @param url
- * the entry point for the service. This is used as id for
- * further identification of the service.
- * @return true, if connect succeeded, false else.
- * @throws WPSClientException
- * wps client exception
- */
- public boolean connectForMonitoring(String url) throws WPSClientException {
- logger.debug("CONNECT");
- if (loggedServices.containsKey(url)) {
- logger.debug("Service already registered: " + url);
- return false;
- }
-
- logger.warn("retrieving caps failed, caps are null");
- return false;
- }
-
- /**
- * removes a service from the session
- *
- * @param url
- * url
- */
- public void disconnect(String url) {
- /*
- * if (loggedServices.containsKey(url)) { loggedServices.remove(url);
- * processDescriptions.remove(url);
- * logger.info("service removed successfully: " + url); }
- */
- }
-
- /**
- * returns the serverIDs of all loggedServices
- *
- * @return list of service
- */
- public List getLoggedServices() {
- if (loggedServices != null && loggedServices.keySet() != null) {
- return new ArrayList(loggedServices.keySet());
- } else {
- return new ArrayList();
- }
- }
-
- /**
- * informs you if the descriptions for the specified service is already in
- * the session. in normal case it should return true :)
- *
- * @param serverID
- * server id
- * @return success if contain descriptions in cache
- */
- public boolean descriptionsAvailableInCache(String serverID) {
- return processDescriptions.containsKey(serverID);
- }
-
- /**
- * returns the cached processdescriptions of a service.
- *
- *
- * @param wpsUrl
- * wps url
- * @return process description document
- * @throws IOException
- * IO exception
- */
- private ProcessDescriptionsDocument getProcessDescriptionsFromCache(String wpsUrl) throws IOException {
- if (!descriptionsAvailableInCache(wpsUrl)) {
- try {
- connect(wpsUrl);
- } catch (WPSClientException e) {
- throw new IOException("Could not initialize WPS " + wpsUrl);
- }
- }
- return processDescriptions.get(wpsUrl);
- }
-
- /**
- * return the processDescription for a specific process from Cache.
- *
- * @param serverID
- * server id
- * @param processID
- * process id
- * @return a ProcessDescription for a specific process from Cache.
- * @throws IOException
- * IO exception
- */
- public ProcessDescriptionType getProcessDescription(String serverID, String processID) throws IOException {
- ProcessDescriptionType[] processes = getProcessDescriptionsFromCache(serverID).getProcessDescriptions()
- .getProcessDescriptionArray();
- for (ProcessDescriptionType process : processes) {
- if (process.getIdentifier().getStringValue().equals(processID)) {
- return process;
- }
- }
- return null;
- }
-
- /**
- * Delivers all ProcessDescriptions from a WPS
- *
- * @param wpsUrl
- * the URL of the WPS
- * @return An Array of ProcessDescriptions
- * @throws IOException
- * IO exception
- */
- public ProcessDescriptionType[] getAllProcessDescriptions(String wpsUrl) throws IOException {
- return getProcessDescriptionsFromCache(wpsUrl).getProcessDescriptions().getProcessDescriptionArray();
- }
-
- /**
- * looks up, if the service exists already in session.
- *
- * @param serverID
- * service id
- * @return true if service is registered
- */
- public boolean serviceAlreadyRegistered(String serverID) {
- return loggedServices.containsKey(serverID);
- }
-
- /**
- * provides you the cached capabilities for a specified service.
- *
- * @param url
- * service url
- * @return capabilities document
- */
- public CapabilitiesDocument getWPSCaps(String url) {
- return loggedServices.get(url);
- }
-
- /**
- * retrieves all current available ProcessDescriptions of a WPS. Mention: to
- * get the current list of all processes, which will be requested, the
- * cached capabilities will be used. Please keep that in mind. the retrieved
- * descriptions will not be cached, so only transient information!
- *
- * @param url
- * service url
- * @return process descriptions document
- * @throws WPSClientException
- * WPS Client expcetion
- */
- public ProcessDescriptionsDocument describeAllProcesses(String url) throws WPSClientException {
- CapabilitiesDocument doc = loggedServices.get(url);
- if (doc == null) {
- logger.warn("serviceCaps are null, perhaps server does not exist");
- return null;
- }
- ProcessBriefType[] processes = doc.getCapabilities().getProcessOfferings().getProcessArray();
- String[] processIDs = new String[processes.length];
- for (int i = 0; i < processIDs.length; i++) {
- processIDs[i] = processes[i].getIdentifier().getStringValue();
- }
- return describeProcess(processIDs, url);
-
- }
-
- /**
- * retrieves the desired description for a service. the retrieved
- * information will not be held in cache!
- *
- *
- * @param processIDs
- * process ids
- * @param serverID
- * server id
- * @return process description document
- * @throws WPSClientException
- * WPS Client expcetion
- */
- public ProcessDescriptionsDocument describeProcess(String[] processIDs, String serverID) throws WPSClientException {
-
- CapabilitiesDocument caps = this.loggedServices.get(serverID);
- Operation[] operations = caps.getCapabilities().getOperationsMetadata().getOperationArray();
- String url = null;
- for (Operation operation : operations) {
- if (operation.getName().equals("DescribeProcess")) {
- url = operation.getDCPArray()[0].getHTTP().getGetArray()[0].getHref();
- }
- }
- if (url == null) {
- throw new WPSClientException("Missing DescribeOperation in Capabilities");
- }
- return retrieveDescriptionViaGET(processIDs, url);
- }
-
- /**
- * Executes a process at a WPS
- *
- * @param url
- * url of server not the entry additionally defined in the caps.
- * @param execute
- * Execute document
- * @return either an ExecuteResponseDocument or an InputStream if asked for
- * RawData or an Exception Report
- */
- /**
- *
- * @param serverID
- * server id
- * @param execute
- * execute document
- * @param rawData
- * true if raw data
- * @return Object
- * @throws WPSClientException
- * WPS Client exception
- */
- private Object execute(String serverID, ExecuteDocument execute, boolean rawData) throws WPSClientException {
- CapabilitiesDocument caps = loggedServices.get(serverID);
- Operation[] operations = caps.getCapabilities().getOperationsMetadata().getOperationArray();
- String url = null;
- for (Operation operation : operations) {
- if (operation.getName().equals("Execute")) {
- url = operation.getDCPArray()[0].getHTTP().getPostArray()[0].getHref();
- }
- }
- if (url == null) {
- throw new WPSClientException(
- "Caps does not contain any information about the entry point for process execution");
- }
- execute.getExecute().setVersion(SUPPORTED_VERSION);
- return retrieveExecuteResponseViaPOST(url, execute, rawData);
- }
-
- /**
- * Executes a process at a WPS
- *
- * @param serverId
- * server id url of server not the entry additionally defined in
- * the caps.
- * @param execute
- * Execute document
- * @return either an ExecuteResponseDocument or an InputStream if asked for
- * RawData or an Exception Report
- * @throws WPSClientException
- * WPS Client Exception
- */
- public Object execute(String serverId, ExecuteDocument execute) throws WPSClientException {
- if (execute.getExecute().isSetResponseForm() == true && execute.getExecute().isSetResponseForm() == true
- && execute.getExecute().getResponseForm().isSetRawDataOutput() == true) {
- return execute(serverId, execute, true);
- } else {
- return execute(serverId, execute, false);
- }
-
- }
-
- private CapabilitiesDocument retrieveCapsViaGET(String url) throws WPSClientException {
- logger.debug("retrieveCapsViaGET: " + url);
- ClientCapabiltiesRequest req = new ClientCapabiltiesRequest();
- url = req.getRequest(url);
-
- try {
- String authString = user + ":" + password;
- logger.debug("auth string: " + authString);
- byte[] authEncBytes = Base64.encodeBase64(authString.getBytes());
- String encoded = new String(authEncBytes);
- logger.debug("Base64 encoded auth string: " + encoded);
-
- URL urlObj = new URL(url);
- HttpURLConnection connection = (HttpURLConnection) urlObj.openConnection();
- connection.setRequestMethod("GET");
- connection.setDoOutput(true);
- connection.setRequestProperty("Authorization", "Basic " + encoded);
- InputStream is = connection.getInputStream();
- Document doc = checkInputStream(is);
- CapabilitiesDocument capabilitiesDocument = CapabilitiesDocument.Factory.parse(doc, options);
- return capabilitiesDocument;
- } catch (MalformedURLException e) {
- e.printStackTrace();
- throw new WPSClientException("Capabilities URL seems to be unvalid: " + url, e);
- } catch (IOException e) {
- e.printStackTrace();
- throw new WPSClientException("Error occured while retrieving capabilities from url: " + url, e);
- } catch (XmlException e) {
- e.printStackTrace();
- throw new WPSClientException("Error occured while parsing XML", e);
- }
- }
-
- private ProcessDescriptionsDocument retrieveDescriptionViaGET(String[] processIDs, String url)
- throws WPSClientException {
- try {
- logger.debug("RetrieveDescription GET: " + processIDs + " url:" + url);
-
- Path tempFile = Files.createTempFile("WPSProcessDescriptions", "txt");
-
- List lines = new ArrayList<>();
- lines.add("");
- Files.write(tempFile, lines, Charset.defaultCharset(), StandardOpenOption.APPEND);
-
- for (String processId : processIDs) {
- String[] process = { processId };
- DClientDescribeProcessRequest req = new DClientDescribeProcessRequest();
- req.setIdentifier(process);
- String requestURL = req.getRequest(url);
-
- String authString = user + ":" + password;
- logger.debug("auth string: " + authString);
- byte[] authEncBytes = Base64.encodeBase64(authString.getBytes());
- String encoded = new String(authEncBytes);
- logger.debug("Base64 encoded auth string: " + encoded);
-
- URL urlObj = new URL(requestURL);
- HttpURLConnection connection = (HttpURLConnection) urlObj.openConnection();
- connection.setRequestMethod("GET");
- connection.setDoOutput(true);
- connection.setRequestProperty("Authorization", "Basic " + encoded);
- InputStream is = connection.getInputStream();
- lines = retrievesSingleDescription(is);
- Files.write(tempFile, lines, Charset.defaultCharset(), StandardOpenOption.APPEND);
- }
- lines = new ArrayList<>();
- lines.add("");
- Files.write(tempFile, lines, Charset.defaultCharset(), StandardOpenOption.APPEND);
-
- logger.debug(tempFile.toString());
- Document doc = null;
- try (InputStream inputStream = Files.newInputStream(tempFile, StandardOpenOption.READ)) {
- doc = checkInputStream(inputStream);
-
- }
- ProcessDescriptionsDocument processDescriptionsDocument = ProcessDescriptionsDocument.Factory.parse(doc,
- options);
-
- Files.delete(tempFile);
- return processDescriptionsDocument;
-
- } catch (MalformedURLException e) {
- logger.error("URL seems not to be valid");
- e.printStackTrace();
- throw new WPSClientException("URL seems not to be valid", e);
- } catch (IOException e) {
- logger.error("Error occured while receiving data");
- e.printStackTrace();
- throw new WPSClientException("Error occured while receiving data", e);
- } catch (XmlException e) {
- logger.error("Error occured while parsing ProcessDescription document");
- e.printStackTrace();
- throw new WPSClientException("Error occured while parsing ProcessDescription document", e);
- } catch (Throwable e) {
- logger.error(e.getLocalizedMessage());
- e.printStackTrace();
- throw new WPSClientException(e.getLocalizedMessage(), new Exception(e));
- }
- }
-
- protected List retrievesSingleDescription(InputStream is) throws WPSClientException {
- try {
- BufferedReader br = new BufferedReader(new InputStreamReader(is));
-
- List lines = new ArrayList<>();
- String line = null;
- boolean elementProcessDescriptionsFound = false;
- boolean elementProcessDescriptionsClosureFound = false;
-
- while ((line = br.readLine()) != null) {
- if (elementProcessDescriptionsFound) {
- if (elementProcessDescriptionsClosureFound) {
- if (line.contains("")) {
- break;
- } else {
- lines.add(line);
- }
- } else {
- int closeIndex = line.indexOf(">");
- if (closeIndex != -1) {
- elementProcessDescriptionsClosureFound = true;
- if (closeIndex == line.length() - 1) {
-
- } else {
-
- }
- }
- }
- } else {
- if (line.contains("");
- if (closeIndex != -1) {
- elementProcessDescriptionsClosureFound = true;
- if (closeIndex == line.length() - 1) {
-
- } else {
-
- }
- }
- } else {
-
- }
- }
- }
- return lines;
- } catch (Throwable e) {
- logger.error(e.getLocalizedMessage());
- e.printStackTrace();
- throw new WPSClientException(e.getLocalizedMessage(), new Exception(e));
- }
- }
-
- private InputStream retrieveDataViaPOST(XmlObject obj, String urlString) throws WPSClientException {
- try {
- logger.debug("RetrieveDataViaPost(): " + urlString);
- String authString = user + ":" + password;
- logger.debug("auth string: " + authString);
- byte[] authEncBytes = Base64.encodeBase64(authString.getBytes());
- String encoded = new String(authEncBytes);
- logger.debug("Base64 encoded auth string: " + encoded);
-
- URL url = new URL(urlString);
- HttpURLConnection conn = (HttpURLConnection) url.openConnection();
-
- conn.setRequestMethod("POST");
- conn.setRequestProperty("Authorization", "Basic " + encoded);
- conn.setRequestProperty("Accept-Encoding", "gzip");
- conn.setRequestProperty("Content-Type", "text/xml; charset=UTF-8");
- conn.setDoOutput(true);
- obj.save(conn.getOutputStream());
- InputStream input = null;
- String encoding = conn.getContentEncoding();
- if (encoding != null && encoding.equalsIgnoreCase("gzip")) {
- logger.debug("Read encoding GZIP");
- input = new GZIPInputStream(conn.getInputStream());
- } else {
- logger.debug("Read encoding: "+encoding);
- input = conn.getInputStream();
- }
- return input;
- } catch (MalformedURLException e) {
- e.printStackTrace();
- throw new WPSClientException("URL seems to be unvalid", e);
- } catch (IOException e) {
- e.printStackTrace();
- throw new WPSClientException("Error while transmission", e);
- }
- }
-
- private Document checkInputStream(InputStream is) throws WPSClientException {
- try {
- DocumentBuilderFactory fac = DocumentBuilderFactory.newInstance();
- fac.setNamespaceAware(true);
- Document doc = fac.newDocumentBuilder().parse(is);
- logger.debug("Document: " + doc);
- if (doc == null) {
- logger.error("Document is null");
- throw new WPSClientException("Error in check input stream: Document is null");
- }
-
- if (getFirstElementNode(doc.getFirstChild()).getLocalName().equals("ExceptionReport")
- && getFirstElementNode(doc.getFirstChild()).getNamespaceURI().equals(OGC_OWS_URI)) {
- try {
- ExceptionReportDocument exceptionDoc = ExceptionReportDocument.Factory.parse(doc);
- logger.debug(exceptionDoc.xmlText(options));
- throw new WPSClientException("Error occured while executing query", exceptionDoc);
- } catch (XmlException e) {
- throw new WPSClientException("Error while parsing ExceptionReport retrieved from server", e);
- }
- } else {
- logger.debug("No Exception Report");
- }
- return doc;
- } catch (SAXException e) {
- logger.error("Error while parsing input: " + e.getLocalizedMessage());
- e.printStackTrace();
- throw new WPSClientException("Error while parsing input", e);
- } catch (IOException e) {
- logger.error("Error occured while transfer: " + e.getLocalizedMessage());
- e.printStackTrace();
- throw new WPSClientException("Error occured while transfer", e);
- } catch (ParserConfigurationException e) {
- logger.error("Error occured, parser is not correctly configured: " + e.getLocalizedMessage());
- e.printStackTrace();
- throw new WPSClientException("Error occured, parser is not correctly configured", e);
- } catch (WPSClientException e) {
- throw e;
- }
- }
-
- private Node getFirstElementNode(Node node) {
- if (node == null) {
- return null;
- }
- if (node.getNodeType() == Node.ELEMENT_NODE) {
- return node;
- } else {
- return getFirstElementNode(node.getNextSibling());
- }
-
- }
-
- private Object retrieveExecuteResponseViaPOST(String url, ExecuteDocument doc, boolean rawData)
- throws WPSClientException {
- InputStream is = retrieveDataViaPOST(doc, url);
- if (rawData) {
- return is;
- }
- Document documentObj = checkInputStream(is);
- ExceptionReportDocument erDoc = null;
- try {
-
- return ExecuteResponseDocument.Factory.parse(documentObj);
- } catch (XmlException e) {
- try {
- erDoc = ExceptionReportDocument.Factory.parse(documentObj);
- } catch (XmlException e1) {
- throw new WPSClientException("Error occured while parsing executeResponse", e);
- }
- return erDoc;
- }
- }
-
- public String[] getProcessNames(String url) throws IOException {
- ProcessDescriptionType[] processes = getProcessDescriptionsFromCache(url).getProcessDescriptions()
- .getProcessDescriptionArray();
- String[] processNames = new String[processes.length];
- for (int i = 0; i < processNames.length; i++) {
- processNames[i] = processes[i].getIdentifier().getStringValue();
- }
- return processNames;
- }
-
- /**
- * Executes a process at a WPS
- *
- * @param urlString
- * url of server not the entry additionally defined in the caps.
- * @param executeAsGETString
- * KVP Execute request
- * @return either an ExecuteResponseDocument or an InputStream if asked for
- * RawData or an Exception Report
- * @throws WPSClientException
- * WPS Client exception
- */
- public Object executeViaGET(String urlString, String executeAsGETString) throws WPSClientException {
- urlString = urlString + executeAsGETString;
- logger.debug("ExecuteViaGet() Url: " + urlString);
- try {
- // TODO
- String authString = user + ":" + password;
- logger.debug("auth string: " + authString);
- byte[] authEncBytes = Base64.encodeBase64(authString.getBytes());
- String encoded = new String(authEncBytes);
- logger.debug("Base64 encoded auth string: " + encoded);
-
- URL url = new URL(urlString);
- HttpURLConnection conn = (HttpURLConnection) url.openConnection();
- conn.setRequestMethod("GET");
- conn.setRequestProperty("Authorization", "Basic " + encoded);
- conn.setDoOutput(true);
- InputStream is = conn.getInputStream();
-
- if (executeAsGETString.toUpperCase().contains("RAWDATA")) {
- logger.debug("ExecuteAsGETString as RAWDATA");
- return is;
- }
- Document doc = checkInputStream(is);
- ExceptionReportDocument erDoc = null;
- logger.debug("ExecuteAsGETString as Document");
-
- try {
- return ExecuteResponseDocument.Factory.parse(doc);
- } catch (XmlException e) {
- e.printStackTrace();
- try {
- erDoc = ExceptionReportDocument.Factory.parse(doc);
- } catch (XmlException e1) {
- e1.printStackTrace();
- throw new WPSClientException("Error occured while parsing executeResponse", e);
-
- }
- throw new WPSClientException("Error occured while parsing executeResponse", erDoc);
- }
- } catch (MalformedURLException e) {
- e.printStackTrace();
- throw new WPSClientException("Capabilities URL seems to be unvalid: " + urlString, e);
- } catch (IOException e) {
- e.printStackTrace();
- throw new WPSClientException("Error occured while retrieving capabilities from url: " + urlString, e);
- }
-
- }
-
- public String cancelComputation(String url, String computationId) throws WPSClientException {
-
- try {
- String authString = user + ":" + password;
- logger.debug("auth string: " + authString);
- byte[] authEncBytes = Base64.encodeBase64(authString.getBytes());
- String encoded = new String(authEncBytes);
- logger.debug("Base64 encoded auth string: " + encoded);
-
- url += "?id=" + computationId;
- URL urlObj = new URL(url);
- HttpURLConnection connection = (HttpURLConnection) urlObj.openConnection();
- connection.setRequestMethod("GET");
- connection.setDoOutput(true);
- connection.setRequestProperty("Authorization", "Basic " + encoded);
- String responseMessage = connection.getResponseMessage();
- return responseMessage;
- } catch (MalformedURLException e) {
- e.printStackTrace();
- throw new WPSClientException("Capabilities URL seems to be unvalid: " + url, e);
- } catch (IOException e) {
- e.printStackTrace();
- throw new WPSClientException("Error occured while retrieving capabilities from url: " + url, e);
- }
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/wps/WPS2DM.java b/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/wps/WPS2DM.java
deleted file mode 100644
index 525440b..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/wps/WPS2DM.java
+++ /dev/null
@@ -1,542 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.server.dmservice.wps;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.List;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
-
-import net.opengis.ows.x11.AllowedValuesDocument.AllowedValues;
-import net.opengis.ows.x11.DomainMetadataType;
-import net.opengis.ows.x11.ValueType;
-import net.opengis.wps.x100.ComplexDataDescriptionType;
-import net.opengis.wps.x100.InputDescriptionType;
-import net.opengis.wps.x100.LiteralInputType;
-import net.opengis.wps.x100.LiteralOutputType;
-import net.opengis.wps.x100.OutputDescriptionType;
-import net.opengis.wps.x100.SupportedComplexDataInputType;
-import net.opengis.wps.x100.SupportedComplexDataType;
-
-import org.gcube.portlets.user.dataminermanager.shared.exception.ServiceException;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ColumnListParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ColumnParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.DateParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.EnumParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.FileParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ListParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.ObjectParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.TabularListParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.TabularParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.TimeParameter;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.WKTGeometryType;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.WKTParameter;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class WPS2DM {
- private final static String SEPARATOR = "|";
-
- private static Logger logger = LoggerFactory.getLogger(WPS2DM.class);
-
- /**
- *
- * @param title
- * title
- * @param minOcc
- * min occurrences
- * @param maxOcc
- * max occurrences
- * @param rangeOccs
- * range occurrences
- * @param id
- * id
- * @param crs
- * crs
- * @return parameter
- */
- public static Parameter manageBoundingBoxInformation(String title, int minOcc, int maxOcc, int rangeOccs, String id,
- String crs) {
- Parameter converted = null;
- title = "Bounding Box Input in OGC 06-121r3 spec. E.g. 102,46,103,47,urn:ogc:def:crs:EPSG:4328 " + title;
- if (crs != null && crs.length() > 0)
- title += " Supported CRS " + crs;
-
- title = buildParameterDescription(title, null, null, minOcc, maxOcc, null);
- if ((maxOcc == 1) || (maxOcc < 0) || (maxOcc == 0))
- converted = new ObjectParameter(id, title, String.class.getName(), " ");
-
- else
- converted = new ListParameter(id, title, String.class.getName(), SEPARATOR);
-
- return converted;
- }
-
- /**
- *
- * @param title
- * title
- * @param minOcc
- * min occurrences
- * @param maxOcc
- * max occurences
- * @param rangeOccs
- * range occurrences
- * @param defaultValue
- * default value
- * @param id
- * id
- * @param uoms
- * uoms
- * @param type
- * type
- * @return parameter
- */
- public static Parameter manageLiteral(String title, int minOcc, int maxOcc, int rangeOccs, String defaultValue,
- String id, String uoms, DomainMetadataType type) {
- Parameter converted = null;
- logger.debug("WPS type:" + type.getStringValue());
- String guessedType = guessWPSLiteralType(type);
- logger.debug("Guessed type: " + guessedType);
-
- // rebuild title
- if ((defaultValue == null || defaultValue.trim().length() == 0))
- defaultValue = guessDefaultValue(guessedType);
-
- logger.debug("Guessed default value: " + defaultValue);
-
- title = buildParameterDescription(title, null, uoms, minOcc, maxOcc, defaultValue);
- if ((maxOcc == 1) || (maxOcc < 0) || (maxOcc == 0)) {
- if (title != null && !title.isEmpty()) {
- if (title.contains("[a sequence of names of columns from ")) {
- Pattern pattern = Pattern
- .compile("a sequence of names of columns from (\\w+) separated by (\\p{ASCII})");
- Matcher matcher = pattern.matcher(title);
- logger.debug("Machter title: " + title);
- logger.debug("Machter find: " + matcher.find());
- logger.debug("Machter group: " + matcher.group());
- logger.debug("Machter start: " + matcher.start());
- logger.debug("Machter end: " + matcher.end());
- logger.debug("Machter Group Count: " + matcher.groupCount());
- String referredTabularParameterName = matcher.group(1);
- logger.debug("Matcher referredTabularParameterName: " + referredTabularParameterName);
- String separator = matcher.group(2);
- logger.debug("Matcher separator: " + separator);
-
- converted = new ColumnListParameter(id, title, referredTabularParameterName, separator);
- } else {
- if (title.contains("[the name of a column from ")) {
- Pattern pattern = Pattern.compile("the name of a column from (\\w+)");
- Matcher matcher = pattern.matcher(title);
- logger.debug("Machter title: " + title);
- logger.debug("Machter find: " + matcher.find());
- logger.debug("Machter group: " + matcher.group());
- logger.debug("Machter start: " + matcher.start());
- logger.debug("Machter end: " + matcher.end());
- logger.debug("Machter Group Count: " + matcher.groupCount());
- String referredTabularParameterName = matcher.group(1);
- logger.debug("Matcher referredTabularParameterName: " + referredTabularParameterName);
-
- converted = new ColumnParameter(id, title, referredTabularParameterName, defaultValue);
- } else {
- if (title.contains("[a sequence of values separated by ")) {
- Pattern pattern = Pattern.compile("a sequence of values separated by (\\p{ASCII})");
- Matcher matcher = pattern.matcher(title);
- logger.debug("Machter title: " + title);
- logger.debug("Machter find: " + matcher.find());
- logger.debug("Machter group: " + matcher.group());
- logger.debug("Machter start: " + matcher.start());
- logger.debug("Machter end: " + matcher.end());
- logger.debug("Machter Group Count: " + matcher.groupCount());
-
- String separator = matcher.group(1);
- logger.debug("Matcher separator: " + separator);
-
- converted = new ListParameter(id, title, guessedType, separator);
- } else {
- if (title.contains("[WKT_")) {
- logger.debug("WKT parameter: " + title);
- converted = retrieveWKTParameter(id, title, defaultValue);
- } else {
- if (title.contains("[DATE]")) {
- logger.debug("DATE parameter: " + title);
- title = title.replace("[DATE]", "");
- converted = new DateParameter(id, title, defaultValue);
- } else {
- if (title.contains("[TIME]")) {
- logger.debug("TIME parameter: " + title);
- title = title.replace("[TIME]", "");
- converted = new TimeParameter(id, title, defaultValue);
- } else {
- converted = new ObjectParameter(id, title, guessPrimitiveType(guessedType),
- defaultValue);
- }
- }
- }
- }
- }
- }
-
- } else {
- converted = new ObjectParameter(id, title, guessPrimitiveType(guessedType), defaultValue);
- }
-
- } else {
- if (guessedType.compareTo(Boolean.class.getName()) == 0) {
- converted = new ObjectParameter(id, title, guessedType, defaultValue);
- } else {
- converted = new ListParameter(id, title, String.class.getName(), SEPARATOR);
- }
-
- }
- return converted;
- }
-
- private static Parameter retrieveWKTParameter(String id, String title, String defaultValue) {
-
- if (title.contains("[WKT_POINT]")) {
- title = title.replace("[WKT_POINT]", "");
- return new WKTParameter(id, title, WKTGeometryType.Point, defaultValue);
- } else {
- if (title.contains("[WKT_LINESTRING]")) {
- title = title.replace("[WKT_LINESTRING]", "");
- return new WKTParameter(id, title, WKTGeometryType.LineString, defaultValue);
- } else {
- if (title.contains("[WKT_POLYGON]")) {
- title = title.replace("[WKT_POLYGON]", "");
- return new WKTParameter(id, title, WKTGeometryType.Polygon, defaultValue);
- } else {
- if (title.contains("[WKT_CIRCLE]")) {
- title = title.replace("[WKT_CIRCLE]", "");
- return new WKTParameter(id, title, WKTGeometryType.Circle, defaultValue);
- } else {
- if (title.contains("[WKT_TRIANGLE]")) {
- title = title.replace("[WKT_TRIANGLE]", "");
- return new WKTParameter(id, title, WKTGeometryType.Triangle, defaultValue);
- } else {
- if (title.contains("[WKT_SQUARE]")) {
- title = title.replace("[WKT_SQUARE]", "");
- return new WKTParameter(id, title, WKTGeometryType.Square, defaultValue);
- } else {
- if (title.contains("[WKT_PENTAGON]")) {
- title = title.replace("[WKT_PENTAGON]", "");
- return new WKTParameter(id, title, WKTGeometryType.Pentagon, defaultValue);
- } else {
- if (title.contains("[WKT_HEXAGON]")) {
- title = title.replace("[WKT_HEXAGON]", "");
- return new WKTParameter(id, title, WKTGeometryType.Hexagon, defaultValue);
- } else {
- if (title.contains("[WKT_BOX]")) {
- title = title.replace("[WKT_BOX]", "");
- return new WKTParameter(id, title, WKTGeometryType.Box, defaultValue);
- } else {
- return new WKTParameter(id, title, WKTGeometryType.Polygon, defaultValue);
- }
- }
- }
- }
- }
- }
- }
- }
- }
- }
-
- /**
- *
- * @param maxMegaBytes
- * max mega bytes
- * @param title
- * title
- * @param minOcc
- * min occurrences
- * @param maxOcc
- * max occurrences
- * @param rangeOccs
- * range occurrences
- * @param id
- * id
- * @param defaultType
- * default type
- * @param supportedTypes
- * supported type
- * @return parameter
- */
- public static Parameter manageComplexData(String maxMegaBytes, String title, int minOcc, int maxOcc, int rangeOccs,
- String id, ComplexDataDescriptionType defaultType, ComplexDataDescriptionType[] supportedTypes) {
- Parameter converted = null;
- String mimeType = null;
- String schema = null;
- String encoding = null;
- ArrayList supportedMimeTypes = new ArrayList();
-
- // GenericFileDataConstants.MIME_TYPE_TEXT_XML
- mimeType = defaultType.getMimeType();
- schema = defaultType.getSchema();
- encoding = defaultType.getEncoding();
-
- logger.debug("Default MimeType: " + mimeType);
- logger.debug("Default Schema: " + schema);
- logger.debug("Default Encoding: " + encoding);
-
- for (ComplexDataDescriptionType supported : supportedTypes) {
- supportedMimeTypes.add(supported.getMimeType());
- }
- // rebuild title
- title = buildParameterDescription(title, maxMegaBytes, null, minOcc, maxOcc, null);
- if ((maxOcc == 1) || (maxOcc < 0) || (maxOcc == 0)) {
- if (title != null && !title.isEmpty()) {
- if (title.contains("[a http link to a table")) {
- converted = new TabularParameter(id, title, " ", new ArrayList(), mimeType,
- supportedMimeTypes);
- } else {
- if (title.contains("[a http link to a file")) {
- if (title.contains("[NETCDF]")) {
- converted = new FileParameter(id, title, mimeType, supportedMimeTypes, true);
- } else {
- converted = new FileParameter(id, title, mimeType, supportedMimeTypes, false);
- }
- } else {
- if (title.contains("[a sequence of http links")) {
- Pattern pattern = Pattern.compile(
- "\\[a sequence of http links separated by (\\p{ASCII}) , each indicating a table");
-
- Matcher matcher = pattern.matcher(title);
- boolean match = false;
- if (match = matcher.find()) {
- logger.debug("Machter title: " + title);
- logger.debug("Machter find: " + match);
- logger.debug("Machter group: " + matcher.group());
- logger.debug("Machter start: " + matcher.start());
- logger.debug("Machter end: " + matcher.end());
- logger.debug("Machter Group Count: " + matcher.groupCount());
- String separator = matcher.group(1);
- logger.debug("Matcher separator: " + separator);
- converted = new TabularListParameter(id, title, separator, mimeType,
- supportedMimeTypes);
- } else {
- if (title.contains("[NETCDF]")) {
- converted = new FileParameter(id, title, mimeType, supportedMimeTypes, true);
- } else {
- converted = new FileParameter(id, title, mimeType, supportedMimeTypes, false);
- }
- }
- } else {
- if (title.contains("[NETCDF]")) {
- converted = new FileParameter(id, title, mimeType, supportedMimeTypes, true);
- } else {
- converted = new FileParameter(id, title, mimeType, supportedMimeTypes, false);
- }
- }
- }
- }
- } else {
- converted = new FileParameter(id, title, mimeType, supportedMimeTypes, false);
- }
- } else {
- converted = new FileParameter(id, title, mimeType, supportedMimeTypes, false);
- }
- return converted;
- }
-
- public static Parameter convert2DMType(InputDescriptionType wpsType) throws ServiceException {
- try {
-
- String id = wpsType.getIdentifier().getStringValue();
-
- String title = wpsType.getTitle() != null ? wpsType.getTitle().getStringValue() : "";
- int minOcc = wpsType.getMinOccurs().intValue();
- int maxOcc = wpsType.getMaxOccurs().intValue();
- int rangeOccs = maxOcc - minOcc;
- if (rangeOccs == 0)
- rangeOccs = 1;
-
- // default
- Parameter converted = new ObjectParameter(id, title, String.class.getName(), " ");
- if (rangeOccs > 1)
- converted = new ListParameter(id, title, String.class.getName(), SEPARATOR);
-
- // Bounding Boxes
- if (wpsType.isSetBoundingBoxData()) {
- logger.debug("Conversion to DM Type->" + id + " is a Bounding Box Input");
- converted = manageBoundingBoxInformation(title, minOcc, maxOcc, rangeOccs, id,
- wpsType.getBoundingBoxData().getDefault().getCRS());
- }
- // Literals
- else if (wpsType.isSetLiteralData()) {
- logger.debug("Conversion to DM Type->" + id + " is a Literal Input");
- LiteralInputType literal = wpsType.getLiteralData();
- String uoms = literal.getUOMs() == null ? "" : literal.getUOMs().getDefault().getUOM().getStringValue();
- String defaultValue = literal.getDefaultValue();
- converted = manageLiteral(title, minOcc, maxOcc, rangeOccs, defaultValue, id, uoms,
- literal.getDataType());
- AllowedValues allowedValues = literal.getAllowedValues();
- if (allowedValues != null) {
- ValueType[] values = allowedValues.getValueArray();
- logger.debug("ValueType[]:" + Arrays.toString(values));
- List enumValues = new ArrayList<>();
-
- for (ValueType v : values) {
- enumValues.add(v.getStringValue());
- }
- if (values.length > 1) {
- ObjectParameter conv = (ObjectParameter) converted;
- if (conv.getType() != null && !conv.getType().isEmpty()
- && conv.getType().compareToIgnoreCase(Boolean.class.getName()) != 0) {
- converted = new EnumParameter(conv.getName(), conv.getDescription(), enumValues,
- conv.getDefaultValue());
- }
- }
- }
- } else if (wpsType.isSetComplexData()) {
- logger.debug("Conversion to DM Type->" + id + " is a Complex Input");
- SupportedComplexDataInputType complex = wpsType.getComplexData();
- String maxMegaBytes = complex.getMaximumMegabytes() != null ? complex.getMaximumMegabytes().toString()
- : "1";
- logger.debug("Max Megabytes: " + maxMegaBytes);
- converted = manageComplexData(maxMegaBytes, title, minOcc, maxOcc, rangeOccs, id,
- complex.getDefault().getFormat(), complex.getSupported().getFormatArray());
-
- }
-
- logger.debug("Conversion to DM Type->Name=" + id);
- logger.debug("Conversion to DM Type->Title=" + title);
- logger.debug("Conversion to DM Type->Number of Inputs to Manage=" + rangeOccs);
-
- return converted;
-
- } catch (Throwable e) {
- e.printStackTrace();
- logger.error(e.getLocalizedMessage());
- throw new ServiceException(e.getLocalizedMessage());
- }
- }
-
- public static Parameter convert2DMType(OutputDescriptionType wpsType) {
-
- String id = wpsType.getIdentifier().getStringValue();
- String title = wpsType.getTitle() != null ? wpsType.getTitle().getStringValue() : "";
-
- // default
- Parameter converted = new ObjectParameter(id, title, String.class.getName(), " ");
-
- logger.debug("Conversion to DM Type->Output id:" + id);
- logger.debug("Conversion to DM Type->Title:" + title);
-
- // Bounding Boxes
- if (wpsType.isSetBoundingBoxOutput()) {
- logger.debug("Bounding Box Output");
- converted = manageBoundingBoxInformation(title, -1, -1, -1, id, "");
- }
- // Literals
- else if (wpsType.isSetLiteralOutput()) {
- logger.debug("Literal Output");
- LiteralOutputType literal = wpsType.getLiteralOutput();
- String uoms = literal.getUOMs() == null ? "" : literal.getUOMs().toString();
- converted = manageLiteral(title, -1, -1, -1, "", id, uoms, literal.getDataType());
- } else if (wpsType.isSetComplexOutput()) {
- logger.debug("Complex Output");
- SupportedComplexDataType complex = wpsType.getComplexOutput();
- converted = manageComplexData("", title, -1, -1, -1, id, complex.getDefault().getFormat(),
- complex.getSupported().getFormatArray());
- }
-
- return converted;
- }
-
- /**
- *
- * @param title
- * title
- * @param maxMegabytes
- * max mega bytes
- * @param UoM
- * UoM
- * @param minElements
- * min elements
- * @param maxElements
- * max elements
- * @param defaultValue
- * default value
- * @return description
- */
- public static String buildParameterDescription(String title, String maxMegabytes, String UoM, int minElements,
- int maxElements, String defaultValue) {
-
- String description = title;
- /*
- * String innerDescription = "";
- *
- * if (maxMegabytes != null && maxMegabytes.trim().length() > 0) {
- * innerDescription += "Max MB Size:" + maxMegabytes.trim() + "; "; } if
- * (UoM != null && UoM.trim().length() > 0) { innerDescription +=
- * "Unit of Measure:" + UoM.trim() + "; "; } if (minElements > 0) {
- * innerDescription += "Min N. of Entries:" + minElements + "; "; } if
- * (maxElements > 0) { innerDescription += "Max N. of Entries:" +
- * maxElements + "; "; } if (defaultValue != null &&
- * defaultValue.trim().length() > 0) { innerDescription += "default:" +
- * defaultValue.trim() + "; "; }
- *
- * if (innerDescription.length() > 0) description += " [" +
- * innerDescription.substring(0,
- * innerDescription.lastIndexOf(";")).trim() + "]";
- */
- return description;
-
- }
-
- public static String guessWPSLiteralType(DomainMetadataType type) {
-
- if (type == null || type.getStringValue() == null)
- return String.class.getName();
- else {
- String typeS = type.getReference().trim();
- if (typeS.length() == 0)
- return String.class.getName();
- else if (typeS.contains("float") || typeS.contains("double") || typeS.contains("decimal"))
- return Double.class.getName();
- else if (typeS.contains("int"))
- return Integer.class.getName();
- else if (typeS.contains("long"))
- return Long.class.getName();
- else if (typeS.contains("short"))
- return Short.class.getName();
- else if (typeS.contains("boolean"))
- return Boolean.class.getName();
-
- }
-
- return String.class.getName();
- }
-
- public static String guessDefaultValue(String type) {
- if (type.equals(String.class.getName()))
- return " ";
- else
- return "0";
- }
-
- public static String guessPrimitiveType(String type) {
-
- if (type.equals(Integer.class.getName())) {
- return Integer.class.getName();
- } else if (type.equals(String.class.getName())) {
- return String.class.getName();
- } else if (type.equals(Boolean.class.getName())) {
- return Boolean.class.getName();
- } else if (type.equals(Double.class.getName())) {
- return Double.class.getName();
- } else if (type.equals(Float.class.getName())) {
- return Float.class.getName();
- } else
- return null;
-
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/wps/computationsvalue/ComputationValueBuilder.java b/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/wps/computationsvalue/ComputationValueBuilder.java
deleted file mode 100644
index bee2e7b..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/server/dmservice/wps/computationsvalue/ComputationValueBuilder.java
+++ /dev/null
@@ -1,152 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.server.dmservice.wps.computationsvalue;
-
-import java.net.URL;
-import java.net.URLConnection;
-import java.util.ArrayList;
-import java.util.LinkedHashMap;
-import java.util.List;
-import java.util.Map;
-
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationItemPropertiesValue;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationValue;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationValueFile;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationValueFileList;
-import org.gcube.portlets.user.dataminermanager.shared.data.computations.ComputationValueImage;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class ComputationValueBuilder {
- private static Logger logger = LoggerFactory.getLogger(ComputationValueBuilder.class);
-
- private ArrayList valueParameters;
- private LinkedHashMap computationsValueParameters;
-
- public ComputationValueBuilder(ArrayList valueParameters) {
- this.valueParameters = valueParameters;
- }
-
- /**
- *
- * @return map from parameter to computation value
- */
- public LinkedHashMap create() {
- computationsValueParameters = new LinkedHashMap();
- if (valueParameters != null && !valueParameters.isEmpty()) {
- for (ComputationItemPropertiesValue valueParameter : valueParameters) {
- String value = valueParameter.getValue();
- if (value != null && !value.isEmpty() && value.startsWith("http")) {
- if (value.contains("|")) {
- ComputationValue valueFileList = createComputationValueFileList(value);
- computationsValueParameters.put(valueParameter.getKey(), valueFileList);
- } else {
- ComputationValue computationValue = retrieveFileName(value);
- computationsValueParameters.put(valueParameter.getKey(), computationValue);
- }
- } else {
- ComputationValue valueString = new ComputationValue(value);
- computationsValueParameters.put(valueParameter.getKey(), valueString);
- }
- }
- }
- logger.debug("CompuatationsValues: " + computationsValueParameters);
- return computationsValueParameters;
-
- }
-
- private ComputationValue createComputationValueFileList(String value) {
- ArrayList fileList = new ArrayList<>();
- int indexSeparator;
- String file;
- ComputationValue computationValue;
- while ((indexSeparator = value.indexOf("|")) != -1) {
- file = value.substring(0, indexSeparator);
- value = value.substring(indexSeparator + 1);
- computationValue = retrieveFileName(file);
- fileList.add(computationValue);
- }
- computationValue = retrieveFileName(value);
- fileList.add(computationValue);
- ComputationValueFileList computationValueFileList = new ComputationValueFileList(fileList, "|");
- return computationValueFileList;
-
- }
-
- private ComputationValue retrieveFileName(final String value) {
- URLConnection conn = null;
- logger.debug("Retrieve File Header from Storage for value: " + value);
- try {
- // Use URL connection because in internal network is more fast
- URL url = new URL(value);
- conn = url.openConnection();
- return extractFileName(conn, value);
-
- } catch (Throwable e) {
- logger.error("Retrieve File Name: " + e.getLocalizedMessage());
- e.printStackTrace();
- return new ComputationValueFile(value, null, null, false);
- }
- }
-
- private ComputationValue extractFileName(URLConnection conn, String value) {
- ComputationValue computationValue = null;
- String fileName = null;
- String mimeType = null;
-
- logger.debug("Connection-Header: " + conn.getHeaderFields());
-
- String contentDisposition = conn.getHeaderField("Content-Disposition");
- if (contentDisposition == null) {
- Map> headerFields = conn.getHeaderFields();
- boolean found = false;
- for (String key : headerFields.keySet()) {
- List headerField = headerFields.get(key);
- for (String fieldValue : headerField) {
- if (fieldValue.toLowerCase().contains("filename=")) {
- contentDisposition = fieldValue;
- found = true;
- break;
- }
- }
- if (found) {
- break;
- }
- }
- }
-
- logger.debug("Content-Disposition: " + contentDisposition);
- // Content-Disposition="attachment; filename=abc.png"
- if (contentDisposition != null && contentDisposition.indexOf("=") != -1) {
- fileName = contentDisposition.split("=")[1]; // getting value
- // after '='
- if (fileName != null && !fileName.isEmpty()) {
- if (fileName.startsWith("\"")) {
- fileName = fileName.substring(1);
- }
- if (fileName.endsWith("\"")) {
- fileName = fileName.substring(0, fileName.length() - 1);
- }
- }
- } else { // fall back to random generated file name? }
- }
- mimeType = conn.getContentType();
- if ((mimeType != null && mimeType.compareToIgnoreCase("image/png") == 0)
- || fileName != null && fileName.endsWith(".png")) {
- computationValue = new ComputationValueImage(value, fileName, mimeType);
- } else {
- if ((mimeType != null && mimeType.compareToIgnoreCase("application/x-netcdf") == 0)
- || fileName != null && fileName.endsWith(".nc")) {
- computationValue = new ComputationValueFile(value, fileName, mimeType, true);
- } else {
- computationValue = new ComputationValueFile(value, fileName, mimeType, false);
- }
- }
-
- return computationValue;
- }
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/server/is/InformationSystemUtils.java b/src/main/java/org/gcube/portlets/user/dataminermanager/server/is/InformationSystemUtils.java
deleted file mode 100644
index f447447..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/server/is/InformationSystemUtils.java
+++ /dev/null
@@ -1,55 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.server.is;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.gcube.common.resources.gcore.ServiceEndpoint;
-import org.gcube.common.scope.api.ScopeProvider;
-import org.gcube.resources.discovery.client.api.DiscoveryClient;
-import org.gcube.resources.discovery.client.queries.api.SimpleQuery;
-import org.gcube.resources.discovery.icclient.ICFactory;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class InformationSystemUtils {
-
- private static Logger logger = LoggerFactory
- .getLogger(InformationSystemUtils.class);
-
- public static List retrieveServiceAddress(String category,
- String name, String scope) throws Exception {
- try {
-
- if (scope == null || scope.length() == 0)
- return new ArrayList();
-
- ScopeProvider.instance.set(scope);
-
- SimpleQuery query = ICFactory.queryFor(ServiceEndpoint.class);
- query.addCondition(
- "$resource/Profile/Category/text() eq '" + category + "'")
- .addCondition(
- "$resource/Profile/Name/text() eq '" + name + "'")
- .setResult(
- "$resource/Profile/AccessPoint/Interface/Endpoint/text()");
- DiscoveryClient client = ICFactory.client();
- List addresses = client.submit(query);
-
- return addresses;
-
- } catch (Throwable e) {
- logger.error("Error in discovery DataMiner Service Endpoint in scope: "
- + scope);
- logger.error("Error: " + e.getLocalizedMessage());
- e.printStackTrace();
- throw e;
- }
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/server/storage/StorageUtil.java b/src/main/java/org/gcube/portlets/user/dataminermanager/server/storage/StorageUtil.java
index 43d8db7..ec7a272 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/server/storage/StorageUtil.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/server/storage/StorageUtil.java
@@ -2,8 +2,6 @@ package org.gcube.portlets.user.dataminermanager.server.storage;
import java.io.File;
import java.io.InputStream;
-import java.text.SimpleDateFormat;
-import java.util.Date;
import java.util.Map;
import org.gcube.common.homelibrary.home.HomeLibrary;
@@ -12,10 +10,6 @@ import org.gcube.common.homelibrary.home.workspace.Workspace;
import org.gcube.common.homelibrary.home.workspace.WorkspaceFolder;
import org.gcube.common.homelibrary.home.workspace.WorkspaceItem;
import org.gcube.common.homelibrary.util.zip.ZipUtil;
-import org.gcube.contentmanagement.blobstorage.service.IClient;
-import org.gcube.contentmanager.storageclient.wrapper.AccessType;
-import org.gcube.contentmanager.storageclient.wrapper.MemoryType;
-import org.gcube.contentmanager.storageclient.wrapper.StorageClient;
import org.gcube.portlets.user.dataminermanager.shared.exception.ServiceException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -255,34 +249,4 @@ public class StorageUtil {
}
- /**
- *
- * @param is
- * input stream
- * @return public link
- * @throws ServiceException
- * service exception
- */
- public static String saveOnStorageInTemporalFile(InputStream is) throws ServiceException {
- try {
- logger.debug("SaveOnStorageInTemporalFile()");
- SimpleDateFormat sdf = new SimpleDateFormat("yyyyMMdd_HHmmss");
- Double v = Math.random() * 10000;
- String tempFile = "P_" + sdf.format(new Date()) + "_" + v.intValue() + ".xml";
- String remotePath = "/DataMiner/AlgoritmsParameters/" + tempFile;
- IClient client = new StorageClient("DataAnalysis", "DataMiner", "DataMiner", AccessType.PUBLIC,
- MemoryType.VOLATILE).getClient();
- String storageId = client.put(true).LFile(is).RFile(remotePath);
- logger.debug("Storage id: " + storageId);
- String publicLink = client.getHttpUrl().RFile(remotePath);
- logger.debug("Storage public link: " + publicLink);
- return publicLink;
-
- } catch (Throwable e) {
- logger.error(e.getLocalizedMessage());
- e.printStackTrace();
- throw new ServiceException(e.getLocalizedMessage(), e);
- }
- }
-
}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/server/util/DataMinerWorkAreaManager.java b/src/main/java/org/gcube/portlets/user/dataminermanager/server/util/DataMinerWorkAreaManager.java
index 9175d70..e84e12e 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/server/util/DataMinerWorkAreaManager.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/server/util/DataMinerWorkAreaManager.java
@@ -4,11 +4,12 @@ package org.gcube.portlets.user.dataminermanager.server.util;
import org.gcube.common.homelibrary.home.workspace.WorkspaceItem;
import org.gcube.portlets.user.dataminermanager.server.storage.StorageUtil;
import org.gcube.portlets.user.dataminermanager.shared.exception.ServiceException;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.Computations;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.OutputDataSets;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.DataMinerWorkArea;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.InputDataSets;
-import org.gcube.portlets.user.dataminermanager.shared.workspace.ItemDescription;
+import org.gcube.data.analysis.dataminermanagercl.server.util.ServiceCredentials;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.Computations;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.OutputDataSets;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.DataMinerWorkArea;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.InputDataSets;
+import org.gcube.data.analysis.dataminermanagercl.shared.workspace.ItemDescription;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/server/util/ServiceCredentials.java b/src/main/java/org/gcube/portlets/user/dataminermanager/server/util/ServiceCredentials.java
deleted file mode 100644
index 4699299..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/server/util/ServiceCredentials.java
+++ /dev/null
@@ -1,141 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.server.util;
-
-import java.io.Serializable;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class ServiceCredentials implements Serializable {
-
- private static final long serialVersionUID = 3560918948310315680L;
- private String userName;
- private String fullName;
- private String name;
- private String lastName;
- private String email;
- private String scope;
- private String groupId;
- private String groupName;
- private String userAvatarURL;
- private String token;
-
- public ServiceCredentials() {
- super();
- }
-
- public ServiceCredentials(String userName, String scope, String token) {
- super();
- this.userName = userName;
- this.scope = scope;
- this.token = token;
- }
-
- public ServiceCredentials(String userName, String fullName, String name,
- String lastName, String email, String scope, String groupId,
- String groupName, String userAvatarURL, String token) {
- super();
- this.userName = userName;
- this.fullName = fullName;
- this.name = name;
- this.lastName = lastName;
- this.email = email;
- this.scope = scope;
- this.groupId = groupId;
- this.groupName = groupName;
- this.userAvatarURL = userAvatarURL;
- this.token = token;
- }
-
- public String getUserName() {
- return userName;
- }
-
- public void setUserName(String userName) {
- this.userName = userName;
- }
-
- public String getFullName() {
- return fullName;
- }
-
- public void setFullName(String fullName) {
- this.fullName = fullName;
- }
-
- public String getName() {
- return name;
- }
-
- public void setName(String name) {
- this.name = name;
- }
-
- public String getLastName() {
- return lastName;
- }
-
- public void setLastName(String lastName) {
- this.lastName = lastName;
- }
-
- public String getEmail() {
- return email;
- }
-
- public void setEmail(String email) {
- this.email = email;
- }
-
- public String getScope() {
- return scope;
- }
-
- public void setScope(String scope) {
- this.scope = scope;
- }
-
- public String getGroupId() {
- return groupId;
- }
-
- public void setGroupId(String groupId) {
- this.groupId = groupId;
- }
-
- public String getGroupName() {
- return groupName;
- }
-
- public void setGroupName(String groupName) {
- this.groupName = groupName;
- }
-
- public String getUserAvatarURL() {
- return userAvatarURL;
- }
-
- public void setUserAvatarURL(String userAvatarURL) {
- this.userAvatarURL = userAvatarURL;
- }
-
- public String getToken() {
- return token;
- }
-
- public void setToken(String token) {
- this.token = token;
- }
-
- @Override
- public String toString() {
- return "ServiceCredentials [userName=" + userName + ", fullName="
- + fullName + ", name=" + name + ", lastName=" + lastName
- + ", email=" + email + ", scope=" + scope + ", groupId="
- + groupId + ", groupName=" + groupName + ", userAvatarURL="
- + userAvatarURL + ", token=" + token + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/server/util/TableReader.java b/src/main/java/org/gcube/portlets/user/dataminermanager/server/util/TableReader.java
index 2b2c6a3..8c71cb1 100644
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/server/util/TableReader.java
+++ b/src/main/java/org/gcube/portlets/user/dataminermanager/server/util/TableReader.java
@@ -9,9 +9,10 @@ import java.util.List;
import net.sf.csv4j.CSVReader;
+import org.gcube.data.analysis.dataminermanagercl.server.util.ServiceCredentials;
import org.gcube.portlets.user.dataminermanager.server.storage.StorageUtil;
-import org.gcube.portlets.user.dataminermanager.shared.data.ColumnItem;
-import org.gcube.portlets.user.dataminermanager.shared.data.TableItemSimple;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.ColumnItem;
+import org.gcube.data.analysis.dataminermanagercl.shared.data.TableItemSimple;
import org.gcube.portlets.user.dataminermanager.shared.exception.ServiceException;
import org.gcube.portlets.widgets.wsexplorer.shared.Item;
import org.slf4j.Logger;
@@ -48,7 +49,7 @@ public class TableReader {
TableItemSimple tableItemSimple=new TableItemSimple(publicLink,item.getName(), item.getType().name());
ArrayList columnItemList=new ArrayList();
for(int i=0; i columns;
-
- /**
- *
- */
- public TableItemSimple() {
- super();
- columns = new ArrayList();
- }
-
- /**
- *
- * @param id
- * id
- * @param name
- * name
- * @param description
- * description
- * @param type
- * type
- */
- public TableItemSimple(String id, String name, String description, String type) {
- super();
- columns = new ArrayList();
- this.id = id;
- this.name = name;
- this.description = description;
- this.type = type;
- }
-
- /**
- *
- * @param id
- * id
- * @param name
- * name
- * @param description
- * description
- */
- public TableItemSimple(String id, String name, String description) {
- super();
- columns = new ArrayList();
- this.id = id;
- this.name = name;
- this.description = description;
- }
-
- /**
- * @return the name
- */
- public String getName() {
- return name;
- }
-
- /**
- * @param name
- * the name to set
- */
- public void setName(String name) {
- this.name = name;
- }
-
- /**
- * @return the description
- */
- public String getDescription() {
- return description;
- }
-
- /**
- * @param description
- * the description to set
- */
- public void setDescription(String description) {
- this.description = description;
- }
-
- /**
- * @return the type
- */
- public String getType() {
- return type;
- }
-
- /**
- * @param type
- * the type to set
- */
- public void setType(String type) {
- this.type = type;
- }
-
- /**
- * @return the id
- */
- public String getId() {
- return id;
- }
-
- /**
- * @param id
- * the id to set
- */
- public void setId(String id) {
- this.id = id;
- }
-
- public ArrayList getColumns() {
- return columns;
- }
-
- public void setColumns(ArrayList columns) {
- this.columns = columns;
- }
-
- @Override
- public String toString() {
- return "TableItemSimple [id=" + id + ", name=" + name + ", description=" + description + ", type=" + type
- + ", columns=" + columns + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationData.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationData.java
deleted file mode 100644
index 139231d..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationData.java
+++ /dev/null
@@ -1,130 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.shared.data.computations;
-
-import java.io.Serializable;
-import java.util.LinkedHashMap;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class ComputationData implements Serializable {
-
- private static final long serialVersionUID = -3039151542008171640L;
- private ComputationId computationId;
- private LinkedHashMap inputParameters;
- private LinkedHashMap outputParameters;
- private String operatorDescription;
- private String startDate;
- private String endDate;
- private String status;
- private String executionType;
- private String vre;
-
- public ComputationData() {
- super();
- }
-
- public ComputationData(ComputationId computationId,
- LinkedHashMap inputParameters,
- LinkedHashMap outputParameters,
- String operatorDescription, String startDate, String endDate,
- String status, String executionType, String vre) {
- super();
- this.computationId = computationId;
- this.inputParameters = inputParameters;
- this.outputParameters = outputParameters;
- this.operatorDescription = operatorDescription;
- this.startDate = startDate;
- this.endDate = endDate;
- this.status = status;
- this.executionType = executionType;
- this.vre = vre;
- }
-
- public ComputationId getComputationId() {
- return computationId;
- }
-
- public void setComputationId(ComputationId computationId) {
- this.computationId = computationId;
- }
-
- public LinkedHashMap getInputParameters() {
- return inputParameters;
- }
-
- public void setInputParameters(LinkedHashMap inputParameters) {
- this.inputParameters = inputParameters;
- }
-
- public LinkedHashMap getOutputParameters() {
- return outputParameters;
- }
-
- public void setOutputParameters(
- LinkedHashMap outputParameters) {
- this.outputParameters = outputParameters;
- }
-
- public String getOperatorDescription() {
- return operatorDescription;
- }
-
- public void setOperatorDescription(String operatorDescription) {
- this.operatorDescription = operatorDescription;
- }
-
- public String getStartDate() {
- return startDate;
- }
-
- public void setStartDate(String startDate) {
- this.startDate = startDate;
- }
-
- public String getEndDate() {
- return endDate;
- }
-
- public void setEndDate(String endDate) {
- this.endDate = endDate;
- }
-
- public String getStatus() {
- return status;
- }
-
- public void setStatus(String status) {
- this.status = status;
- }
-
- public String getExecutionType() {
- return executionType;
- }
-
- public void setExecutionType(String executionType) {
- this.executionType = executionType;
- }
-
- public String getVre() {
- return vre;
- }
-
- public void setVre(String vre) {
- this.vre = vre;
- }
-
- @Override
- public String toString() {
- return "ComputationData [computationId=" + computationId
- + ", inputParameters=" + inputParameters
- + ", outputParameters=" + outputParameters
- + ", operatorDescription=" + operatorDescription
- + ", startDate=" + startDate + ", endDate=" + endDate
- + ", status=" + status + ", executionType=" + executionType
- + ", vre=" + vre + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationId.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationId.java
deleted file mode 100644
index 18c508b..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationId.java
+++ /dev/null
@@ -1,81 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.shared.data.computations;
-
-import java.io.Serializable;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class ComputationId implements Serializable {
-
- private static final long serialVersionUID = 7898676192287822723L;
- private String id;
- private String urlId;
- private String operatorId;
- private String operatorName;
- private String equivalentRequest;
-
- public ComputationId() {
- super();
- }
-
- public ComputationId(String id, String urlId, String operatorId,
- String operatorName, String equivalentRequest) {
- super();
- this.id = id;
- this.urlId = urlId;
- this.operatorId = operatorId;
- this.operatorName = operatorName;
- this.equivalentRequest = equivalentRequest;
- }
-
- public String getId() {
- return id;
- }
-
- public void setId(String id) {
- this.id = id;
- }
-
- public String getUrlId() {
- return urlId;
- }
-
- public void setUrlId(String urlId) {
- this.urlId = urlId;
- }
-
- public String getOperatorId() {
- return operatorId;
- }
-
- public void setOperatorId(String operatorId) {
- this.operatorId = operatorId;
- }
-
- public String getOperatorName() {
- return operatorName;
- }
-
- public void setOperatorName(String operatorName) {
- this.operatorName = operatorName;
- }
-
- public String getEquivalentRequest() {
- return equivalentRequest;
- }
-
- public void setEquivalentRequest(String equivalentRequest) {
- this.equivalentRequest = equivalentRequest;
- }
-
- @Override
- public String toString() {
- return "ComputationId [id=" + id + ", urlId=" + urlId + ", operatorId="
- + operatorId + ", operatorName=" + operatorName
- + ", equivalentRequest=" + equivalentRequest + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationItemPropertiesValue.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationItemPropertiesValue.java
deleted file mode 100644
index 48e3c64..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationItemPropertiesValue.java
+++ /dev/null
@@ -1,66 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.shared.data.computations;
-
-import java.io.Serializable;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class ComputationItemPropertiesValue implements Serializable,
- Comparable {
-
- private static final long serialVersionUID = 8917614711815918760L;
- private Integer order;
- private String key;
- private String value;
-
- public ComputationItemPropertiesValue() {
- super();
- }
-
- public ComputationItemPropertiesValue(Integer order, String key,
- String value) {
- super();
- this.order = order;
- this.key = key;
- this.value = value;
- }
-
- public Integer getOrder() {
- return order;
- }
-
- public void setOrder(Integer order) {
- this.order = order;
- }
-
- public String getKey() {
- return key;
- }
-
- public void setKey(String key) {
- this.key = key;
- }
-
- public String getValue() {
- return value;
- }
-
- public void setValue(String value) {
- this.value = value;
- }
-
- @Override
- public int compareTo(ComputationItemPropertiesValue o) {
- return order.compareTo(o.getOrder());
- }
-
- @Override
- public String toString() {
- return "ComputationItemPropertiesValue [order=" + order + ", key="
- + key + ", value=" + value + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationValue.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationValue.java
deleted file mode 100644
index 7e0cd55..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationValue.java
+++ /dev/null
@@ -1,60 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.shared.data.computations;
-
-import java.io.Serializable;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class ComputationValue implements Serializable {
-
- private static final long serialVersionUID = -2047623108851748745L;
- protected ComputationValueType type;
- protected String value;
-
- public ComputationValue() {
- super();
- this.type = ComputationValueType.String;
- }
-
- public ComputationValue(ComputationValueType type) {
- super();
- this.type = type;
- }
-
- public ComputationValue(String value) {
- super();
- this.type = ComputationValueType.String;
- this.value = value;
- }
-
- public ComputationValue(ComputationValueType type, String value) {
- super();
- this.type = type;
- this.value = value;
- }
-
- public ComputationValueType getType() {
- return type;
- }
-
- public void setType(ComputationValueType type) {
- this.type = type;
- }
-
- public String getValue() {
- return value;
- }
-
- public void setValue(String value) {
- this.value = value;
- }
-
- @Override
- public String toString() {
- return "ComputationValue [type=" + type + ", value=" + value + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationValueFile.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationValueFile.java
deleted file mode 100644
index e7a6aee..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationValueFile.java
+++ /dev/null
@@ -1,56 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.shared.data.computations;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class ComputationValueFile extends ComputationValue {
- private static final long serialVersionUID = -5845606225432949795L;
-
- private String fileName;
- private String mimeType;
- private boolean netcdf;
-
- public ComputationValueFile() {
- super(ComputationValueType.File);
- }
-
- public ComputationValueFile(String url, String fileName, String mimeType, boolean netcdf) {
- super(ComputationValueType.File, url);
- this.fileName = fileName;
- this.mimeType = mimeType;
- this.netcdf = netcdf;
- }
-
- public String getFileName() {
- return fileName;
- }
-
- public void setFileName(String fileName) {
- this.fileName = fileName;
- }
-
- public String getMimeType() {
- return mimeType;
- }
-
- public void setMimeType(String mimeType) {
- this.mimeType = mimeType;
- }
-
- public boolean isNetcdf() {
- return netcdf;
- }
-
- public void setNetcdf(boolean netcdf) {
- this.netcdf = netcdf;
- }
-
- @Override
- public String toString() {
- return "ComputationValueFile [fileName=" + fileName + ", mimeType=" + mimeType + ", netcdf=" + netcdf + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationValueFileList.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationValueFileList.java
deleted file mode 100644
index 917e01b..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationValueFileList.java
+++ /dev/null
@@ -1,55 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.shared.data.computations;
-
-import java.util.ArrayList;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class ComputationValueFileList extends ComputationValue {
- private static final long serialVersionUID = -5845606225432949795L;
-
- private ArrayList fileList;
- private String separator;
-
- public ComputationValueFileList() {
- super(ComputationValueType.FileList);
- }
-
- public ComputationValueFileList(ArrayList fileList,
- String separator) {
- super(ComputationValueType.FileList);
- this.fileList = fileList;
- this.separator = separator;
- value = new String();
- for (ComputationValue file : fileList) {
- value = value + file.getValue();
- }
- }
-
- public ArrayList getFileList() {
- return fileList;
- }
-
- public void setFileList(ArrayList fileList) {
- this.fileList = fileList;
- }
-
- public String getSeparator() {
- return separator;
- }
-
- public void setSeparator(String separator) {
- this.separator = separator;
- }
-
- @Override
- public String toString() {
- return "ComputationValueFileList [fileList=" + fileList
- + ", separator=" + separator + ", type=" + type + ", value="
- + value + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationValueImage.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationValueImage.java
deleted file mode 100644
index be44289..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationValueImage.java
+++ /dev/null
@@ -1,47 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.shared.data.computations;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class ComputationValueImage extends ComputationValue {
- private static final long serialVersionUID = -5845606225432949795L;
-
- private String fileName;
- private String mimeType;
-
- public ComputationValueImage(){
- super(ComputationValueType.Image);
- }
-
- public ComputationValueImage(String url, String fileName, String mimeType) {
- super(ComputationValueType.Image, url);
- this.fileName = fileName;
- this.mimeType = mimeType;
- }
-
- public String getFileName() {
- return fileName;
- }
-
- public void setFileName(String fileName) {
- this.fileName = fileName;
- }
-
- public String getMimeType() {
- return mimeType;
- }
-
- public void setMimeType(String mimeType) {
- this.mimeType = mimeType;
- }
-
- @Override
- public String toString() {
- return "ComputationValueImage [fileName=" + fileName + ", mimeType="
- + mimeType + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationValueType.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationValueType.java
deleted file mode 100644
index a12411c..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/computations/ComputationValueType.java
+++ /dev/null
@@ -1,11 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.shared.data.computations;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public enum ComputationValueType {
- FileList, File, Image, String;
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/output/FileResource.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/output/FileResource.java
deleted file mode 100644
index af8d47e..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/output/FileResource.java
+++ /dev/null
@@ -1,111 +0,0 @@
-/**
- *
- */
-package org.gcube.portlets.user.dataminermanager.shared.data.output;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class FileResource extends Resource {
-
- /**
- *
- */
- private static final long serialVersionUID = 799627064179136509L;
-
- private String url;
- private String mimeType;
- private boolean netcdf;
-
- /**
- *
- */
- public FileResource() {
- super();
- this.setResourceType(ResourceType.FILE);
- }
-
- /**
- *
- * @param resourceId
- * resource id
- * @param name
- * name
- * @param description
- * description
- * @param url
- * url
- * @param mimeType
- * mime type
- * @param netcdf
- * netcdf
- */
- public FileResource(String resourceId, String name, String description, String url, String mimeType,
- boolean netcdf) {
- super(resourceId, name, description, ResourceType.FILE);
- this.url = url;
- this.mimeType = mimeType;
- this.netcdf = netcdf;
- }
-
- /**
- * @return the url
- */
- public String getUrl() {
- return url;
- }
-
- /**
- * @param url
- * the url to set
- */
- public void setUrl(String url) {
- this.url = url;
- }
-
- /**
- * @return the mimeType
- */
- public String getMimeType() {
- return mimeType;
- }
-
- /**
- * @param mimeType
- * the mimeType to set
- */
- public void setMimeType(String mimeType) {
- this.mimeType = mimeType;
- }
-
- /**
- *
- * @return true if is NetCDF file
- */
- public boolean isNetcdf() {
- return netcdf;
- }
-
- /**
- *
- * @param netcdf
- * true if is NetCDF file
- */
- public void setNetcdf(boolean netcdf) {
- this.netcdf = netcdf;
- }
-
- @Override
- public String toString() {
- return "FileResource [url=" + url + ", mimeType=" + mimeType + ", netcdf=" + netcdf + ", getResourceId()="
- + getResourceId() + ", getName()=" + getName() + ", getDescription()=" + getDescription()
- + ", getResourceType()=" + getResourceType() + ", isTabular()=" + isTabular() + ", isObject()="
- + isObject() + ", isFile()=" + isFile() + ", isMap()=" + isMap() + ", isImages()=" + isImages()
- + ", isError()=" + isError() + ", toString()=" + super.toString() + ", getClass()=" + getClass()
- + ", hashCode()=" + hashCode() + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/output/ImageResource.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/output/ImageResource.java
deleted file mode 100644
index edd3379..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/output/ImageResource.java
+++ /dev/null
@@ -1,79 +0,0 @@
-/**
- *
- */
-package org.gcube.portlets.user.dataminermanager.shared.data.output;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class ImageResource extends Resource {
-
- /**
- *
- */
- private static final long serialVersionUID = 8772836076910728324L;
- private String link;
- private String mimeType;
-
- /**
- *
- */
- public ImageResource() {
- super();
- this.setResourceType(ResourceType.IMAGE);
- }
-
- /**
- *
- * @param resourceId
- * resource id
- * @param name
- * name
- * @param description
- * description
- * @param link
- * link
- * @param mimeType
- * mime type
- */
- public ImageResource(String resourceId, String name, String description, String link, String mimeType) {
- super(resourceId, name, description, ResourceType.IMAGE);
- this.link = link;
- this.mimeType = mimeType;
- }
-
- /**
- *
- * @return link
- */
- public String getLink() {
- return link;
- }
-
- /**
- *
- * @param link link
- */
- public void setLink(String link) {
- this.link = link;
- }
-
- public String getMimeType() {
- return mimeType;
- }
-
- public void setMimeType(String mimeType) {
- this.mimeType = mimeType;
- }
-
- @Override
- public String toString() {
- return "ImagesResource [link=" + link + ", mimeType=" + mimeType + ", getResourceId()=" + getResourceId()
- + ", getName()=" + getName() + ", getDescription()=" + getDescription() + ", getResourceType()="
- + getResourceType() + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/output/MapResource.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/output/MapResource.java
deleted file mode 100644
index 5dfd949..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/output/MapResource.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/**
- *
- */
-package org.gcube.portlets.user.dataminermanager.shared.data.output;
-
-import java.util.LinkedHashMap;
-import java.util.Map;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class MapResource extends Resource {
-
- private static final long serialVersionUID = 8772836076910728324L;
- private LinkedHashMap map;
-
- public MapResource() {
- super();
- this.setResourceType(ResourceType.MAP);
- }
-
- /**
- *
- * @param resourceId
- * resource id
- * @param name
- * name
- * @param description
- * description
- * @param map
- * map of resources
- */
- public MapResource(String resourceId, String name, String description, LinkedHashMap map) {
- super(resourceId, name, description, ResourceType.MAP);
- this.map = map;
- }
-
- public Map getMap() {
- return map;
- }
-
- public void setMap(LinkedHashMap map) {
- this.map = map;
- }
-
- @Override
- public String toString() {
- return "MapResource [map=" + map + ", getResourceId()=" + getResourceId() + ", getName()=" + getName()
- + ", getDescription()=" + getDescription() + ", getResourceType()=" + getResourceType() + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/output/ObjectResource.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/output/ObjectResource.java
deleted file mode 100644
index 05900ef..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/output/ObjectResource.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/**
- *
- */
-package org.gcube.portlets.user.dataminermanager.shared.data.output;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class ObjectResource extends Resource {
-
- /**
- *
- */
- private static final long serialVersionUID = 8772836076910728324L;
- private String value;
-
- /**
- *
- */
- public ObjectResource() {
- super();
- this.setResourceType(ResourceType.OBJECT);
- }
-
- /**
- *
- * @param resourceId
- * resource id
- * @param name
- * name
- * @param description
- * description
- * @param value
- * value
- */
- public ObjectResource(String resourceId, String name, String description, String value) {
- super(resourceId, name, description, ResourceType.OBJECT);
- this.value = value;
- }
-
- /**
- * @return the url
- */
- public String getValue() {
- return value;
- }
-
- /**
- *
- * @param value
- * value
- */
- public void setValue(String value) {
- this.value = value;
- }
-
- @Override
- public String toString() {
- return "ObjectResource [value=" + value + ", getResourceId()=" + getResourceId() + ", getName()=" + getName()
- + ", getDescription()=" + getDescription() + ", getResourceType()=" + getResourceType() + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/output/Resource.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/output/Resource.java
deleted file mode 100644
index 5997818..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/output/Resource.java
+++ /dev/null
@@ -1,144 +0,0 @@
-/**
- *
- */
-package org.gcube.portlets.user.dataminermanager.shared.data.output;
-
-import java.io.Serializable;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class Resource implements Serializable {
-
- /**
- *
- */
- private static final long serialVersionUID = 1417885805472591661L;
-
- public enum ResourceType {
- OBJECT, FILE, TABULAR, MAP, IMAGE, ERROR
- };
-
- private String resourceId, name, description;
- private ResourceType resourceType;
-
- /**
- *
- */
- public Resource() {
- super();
- }
-
- /**
- *
- * @param resourceId
- * resource id
- * @param name
- * name
- * @param description
- * description
- * @param resourceType
- * resource type
- */
- public Resource(String resourceId, String name, String description, ResourceType resourceType) {
- super();
- this.resourceId = resourceId;
- this.name = name;
- this.description = description;
- this.resourceType = resourceType;
- }
-
- /**
- * @return the resource id
- */
- public String getResourceId() {
- return resourceId;
- }
-
- /**
- * @param resourceId
- * the resource id to set
- */
- public void setResourceId(String resourceId) {
- this.resourceId = resourceId;
- }
-
- /**
- * @return the name
- */
- public String getName() {
- return name;
- }
-
- /**
- * @param name
- * the name to set
- */
- public void setName(String name) {
- this.name = name;
- }
-
- /**
- * @return the description
- */
- public String getDescription() {
- return description;
- }
-
- /**
- * @param description
- * the description to set
- */
- public void setDescription(String description) {
- this.description = description;
- }
-
- /**
- * @return the resourceType
- */
- public ResourceType getResourceType() {
- return resourceType;
- }
-
- /**
- * @param resourceType
- * the resourceType to set
- */
- public void setResourceType(ResourceType resourceType) {
- this.resourceType = resourceType;
- }
-
- public boolean isTabular() {
- return this.resourceType == ResourceType.TABULAR;
- }
-
- public boolean isObject() {
- return this.resourceType == ResourceType.OBJECT;
- }
-
- public boolean isFile() {
- return this.resourceType == ResourceType.FILE;
- }
-
- public boolean isMap() {
- return this.resourceType == ResourceType.MAP;
- }
-
- public boolean isImages() {
- return this.resourceType == ResourceType.IMAGE;
- }
-
- public boolean isError() {
- return this.resourceType == ResourceType.ERROR;
- }
-
- @Override
- public String toString() {
- return "Resource [resourceId=" + resourceId + ", name=" + name + ", description=" + description
- + ", resourceType=" + resourceType + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/output/TableResource.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/output/TableResource.java
deleted file mode 100644
index e48f19a..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/data/output/TableResource.java
+++ /dev/null
@@ -1,60 +0,0 @@
-/**
- *
- */
-package org.gcube.portlets.user.dataminermanager.shared.data.output;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class TableResource extends Resource {
-
- private static final long serialVersionUID = -1506902532089828988L;
- private String template;
-
- public TableResource() {
- super();
- this.setResourceType(ResourceType.TABULAR);
- }
-
- /**
- *
- * @param resourceId
- * resource id
- * @param name
- * name
- * @param description
- * description
- * @param template
- * template
- */
- public TableResource(String resourceId, String name, String description, String template) {
- super(resourceId, name, description, ResourceType.TABULAR);
- this.template = template;
- }
-
- /**
- * @return the template
- */
- public String getTemplate() {
- return template;
- }
-
- /**
- * @param template
- * the template to set
- */
- public void setTemplate(String template) {
- this.template = template;
- }
-
- @Override
- public String toString() {
- return "TableResource [template=" + template + ", getResourceId()=" + getResourceId() + ", getName()="
- + getName() + ", getDescription()=" + getDescription() + ", getResourceType()=" + getResourceType()
- + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/ColumnListParameter.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/ColumnListParameter.java
deleted file mode 100644
index be368e0..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/ColumnListParameter.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/**
- *
- */
-package org.gcube.portlets.user.dataminermanager.shared.parameters;
-
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class ColumnListParameter extends Parameter {
-
- private static final long serialVersionUID = -6743494426144267089L;
- private String referredTabularParameterName;
- // private List columnNames = new ArrayList();
- private String separator;
-
- public ColumnListParameter() {
- super();
- this.typology = ParameterType.COLUMN_LIST;
- }
-
- public ColumnListParameter(String name, String description,
- String referredTabularParameterName, String separator) {
- super(name, ParameterType.COLUMN_LIST, description);
- this.referredTabularParameterName = referredTabularParameterName;
- this.separator = separator;
- }
-
- /**
- * @param referredTabularParameterName
- * the referredTabularParameterName to set
- */
- public void setReferredTabularParameterName(
- String referredTabularParameterName) {
- this.referredTabularParameterName = referredTabularParameterName;
- }
-
- /**
- * @return the referredTabularParameterName
- */
- public String getReferredTabularParameterName() {
- return referredTabularParameterName;
- }
-
-
- /**
- * @return the separator
- */
- public String getSeparator() {
- return separator;
- }
-
- public void setSeparator(String separator) {
- this.separator = separator;
- }
-
- @Override
- public String toString() {
- return "ColumnListParameter [referredTabularParameterName="
- + referredTabularParameterName + ", value=" + value
- + ", separator=" + separator + ", name=" + name
- + ", description=" + description + ", typology=" + typology
- + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/ColumnParameter.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/ColumnParameter.java
deleted file mode 100644
index f14a16e..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/ColumnParameter.java
+++ /dev/null
@@ -1,84 +0,0 @@
-/**
- *
- */
-package org.gcube.portlets.user.dataminermanager.shared.parameters;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class ColumnParameter extends Parameter {
-
- /**
- *
- */
- private static final long serialVersionUID = -5084557326770554659L;
- private String referredTabularParameterName;
- private String defaultColumn;
-
- /**
- *
- */
- public ColumnParameter() {
- super();
- this.typology = ParameterType.COLUMN;
- }
-
- /**
- *
- * @param name
- * name
- * @param description
- * description
- * @param referredTabularParameterName
- * reffered tabular parameter name
- * @param defaultColumn
- * default column
- */
- public ColumnParameter(String name, String description, String referredTabularParameterName, String defaultColumn) {
- super(name, ParameterType.COLUMN, description);
- this.referredTabularParameterName = referredTabularParameterName;
- this.defaultColumn = defaultColumn;
- }
-
- /**
- * @param referredTabularParameterName
- * the referredTabularParameterName to set
- */
- public void setReferredTabularParameterName(String referredTabularParameterName) {
- this.referredTabularParameterName = referredTabularParameterName;
- }
-
- /**
- * @return the referredTabularParameterName
- */
- public String getReferredTabularParameterName() {
- return referredTabularParameterName;
- }
-
- /**
- * @return the defaultValue
- */
- public String getDefaultColumn() {
- return defaultColumn;
- }
-
- /**
- *
- * @param defaultColumn
- * default column
- */
- public void setDefaultColumn(String defaultColumn) {
- this.defaultColumn = defaultColumn;
- }
-
- @Override
- public String toString() {
- return "ColumnParameter [referredTabularParameterName=" + referredTabularParameterName + ", defaultColumn="
- + defaultColumn + ", value=" + value + ", name=" + name + ", description=" + description + ", typology="
- + typology + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/DateParameter.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/DateParameter.java
deleted file mode 100644
index a066e1c..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/DateParameter.java
+++ /dev/null
@@ -1,60 +0,0 @@
-/**
- *
- */
-package org.gcube.portlets.user.dataminermanager.shared.parameters;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class DateParameter extends Parameter {
-
- private static final long serialVersionUID = 1673874854501249519L;
- private String defaultValue;
-
- /**
- *
- */
- public DateParameter() {
- super();
- this.typology = ParameterType.DATE;
- }
-
- /**
- *
- * @param name
- * name
- * @param description
- * description
- * @param defaultValue
- * default value
- */
- public DateParameter(String name, String description, String defaultValue) {
- super(name, ParameterType.DATE, description);
- this.defaultValue = defaultValue;
- }
-
- /**
- * @return the defaultValue
- */
- public String getDefaultValue() {
- return defaultValue;
- }
-
- /**
- * @param defaultValue
- * the default value to set
- */
- public void setDefaultValue(String defaultValue) {
- this.defaultValue = defaultValue;
- }
-
- @Override
- public String toString() {
- return "DateParameter [defaultValue=" + defaultValue + ", value=" + value + ", name=" + name + ", description="
- + description + ", typology=" + typology + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/EnumParameter.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/EnumParameter.java
deleted file mode 100644
index 0025604..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/EnumParameter.java
+++ /dev/null
@@ -1,86 +0,0 @@
-/**
- *
- */
-package org.gcube.portlets.user.dataminermanager.shared.parameters;
-
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class EnumParameter extends Parameter {
-
- private static final long serialVersionUID = 1673874854501249519L;
- private List values = new ArrayList();
- private String defaultValue;
-
- /**
- *
- */
- public EnumParameter() {
- super();
- this.typology = ParameterType.ENUM;
- }
-
- /**
- *
- * @param name
- * name
- * @param description
- * description
- * @param values
- * list of value
- * @param defaultValue
- * default value
- */
- public EnumParameter(String name, String description, List values, String defaultValue) {
- super(name, ParameterType.ENUM, description);
- this.values = values;
- this.defaultValue = defaultValue;
- }
-
- /**
- * @return the default value
- */
- public String getDefaultValue() {
- return defaultValue;
- }
-
- /**
- * @param defaultValue
- * the default value to set
- */
- public void setDefaultValue(String defaultValue) {
- this.defaultValue = defaultValue;
- }
-
- /**
- * @param values
- * the values to set
- */
- public void setValues(List values) {
- this.values = values;
- }
-
- /**
- * @return the values
- */
- public List getValues() {
- return values;
- }
-
- public void addValue(String value) {
- this.values.add(value);
- }
-
- @Override
- public String toString() {
- return "EnumParameter [values=" + values + ", defaultValue=" + defaultValue + ", value=" + value + ", name="
- + name + ", description=" + description + ", typology=" + typology + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/FileParameter.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/FileParameter.java
deleted file mode 100644
index 6947023..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/FileParameter.java
+++ /dev/null
@@ -1,82 +0,0 @@
-/**
- *
- */
-package org.gcube.portlets.user.dataminermanager.shared.parameters;
-
-import java.util.ArrayList;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class FileParameter extends Parameter {
-
- private static final long serialVersionUID = -2967577990287112937L;
- private String defaultMimeType;
- private ArrayList supportedMimeTypes;
- private boolean netcdf;
-
- /**
- *
- */
- public FileParameter() {
- super();
- this.typology = ParameterType.FILE;
- netcdf = false;
- }
-
- /**
- *
- * @param name
- * name
- * @param description
- * description
- * @param defaultMimeType
- * default mime type
- * @param supportedMimeTypes
- * supported mime types
- * @param netcdf
- * is netcdf file
- */
- public FileParameter(String name, String description, String defaultMimeType, ArrayList supportedMimeTypes,
- boolean netcdf) {
- super(name, ParameterType.FILE, description);
- this.defaultMimeType = defaultMimeType;
- this.supportedMimeTypes = supportedMimeTypes;
- this.netcdf = netcdf;
- }
-
- public String getDefaultMimeType() {
- return defaultMimeType;
- }
-
- public void setDefaultMimeType(String defaultMimeType) {
- this.defaultMimeType = defaultMimeType;
- }
-
- public ArrayList getSupportedMimeTypes() {
- return supportedMimeTypes;
- }
-
- public void setSupportedMimeTypes(ArrayList supportedMimeTypes) {
- this.supportedMimeTypes = supportedMimeTypes;
- }
-
- public boolean isNetcdf() {
- return netcdf;
- }
-
- public void setNetcdf(boolean netcdf) {
- this.netcdf = netcdf;
- }
-
- @Override
- public String toString() {
- return "FileParameter [defaultMimeType=" + defaultMimeType + ", supportedMimeTypes=" + supportedMimeTypes
- + ", netcdf=" + netcdf + ", name=" + name + ", description=" + description + ", typology=" + typology
- + ", value=" + value + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/ListParameter.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/ListParameter.java
deleted file mode 100644
index fdc0a36..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/ListParameter.java
+++ /dev/null
@@ -1,75 +0,0 @@
-/**
- *
- */
-package org.gcube.portlets.user.dataminermanager.shared.parameters;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class ListParameter extends Parameter {
-
- private static final long serialVersionUID = 5405965026753332225L;
- private String type;
- private String separator;
-
- /**
- *
- */
- public ListParameter() {
- super();
- this.typology = ParameterType.LIST;
- }
-
- /**
- *
- * @param name
- * name
- * @param description
- * description
- * @param type
- * type
- * @param separator
- * separator
- */
- public ListParameter(String name, String description, String type, String separator) {
- super(name, ParameterType.LIST, description);
- this.type = type;
- this.separator = separator;
- }
-
- /**
- * @return the type
- */
- public String getType() {
- return type;
- }
-
- /**
- * @param type
- * the type to set
- */
- public void setType(String type) {
- this.type = type;
- }
-
- /**
- * @return the separator
- */
- public String getSeparator() {
- return separator;
- }
-
- public void setSeparator(String separator) {
- this.separator = separator;
- }
-
- @Override
- public String toString() {
- return "ListParameter [type=" + type + ", value=" + value + ", separator=" + separator + ", name=" + name
- + ", description=" + description + ", typology=" + typology + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/ObjectParameter.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/ObjectParameter.java
deleted file mode 100644
index d0c3f9c..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/ObjectParameter.java
+++ /dev/null
@@ -1,76 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.shared.parameters;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class ObjectParameter extends Parameter {
-
- private static final long serialVersionUID = 1058462575242430851L;
- private String type;
- private String defaultValue;
-
- /**
- *
- */
- public ObjectParameter() {
- super();
- this.typology = ParameterType.OBJECT;
- }
-
- /**
- *
- * @param name
- * name
- * @param description
- * description
- * @param type
- * type
- * @param defaultValue
- * default value
- */
- public ObjectParameter(String name, String description, String type, String defaultValue) {
- super(name, ParameterType.OBJECT, description);
- this.type = type;
- this.defaultValue = defaultValue;
- }
-
- /**
- * @return the type
- */
- public String getType() {
- return type;
- }
-
- /**
- * @param type
- * the type to set
- */
- public void setType(String type) {
- this.type = type;
- }
-
- /**
- * @return the defaultValue
- */
- public String getDefaultValue() {
- return defaultValue;
- }
-
- /**
- * @param defaultValue
- * the defaultValue to set
- */
- public void setDefaultValue(String defaultValue) {
- this.defaultValue = defaultValue;
- }
-
- @Override
- public String toString() {
- return "ObjectParameter [type=" + type + ", defaultValue=" + defaultValue + ", value=" + value + ", name="
- + name + ", description=" + description + ", typology=" + typology + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/Parameter.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/Parameter.java
deleted file mode 100644
index 3ec7644..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/Parameter.java
+++ /dev/null
@@ -1,110 +0,0 @@
-/**
- *
- */
-package org.gcube.portlets.user.dataminermanager.shared.parameters;
-
-import java.io.Serializable;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public abstract class Parameter implements Serializable {
-
- /**
- *
- */
- private static final long serialVersionUID = -555286289487491703L;
-
- protected String name;
- protected String description;
- protected ParameterType typology;
- protected String value;
-
- /**
- *
- */
- public Parameter() {
- super();
- }
-
- /**
- *
- * @param name
- * name
- * @param type
- * type
- * @param description
- * description
- */
- public Parameter(String name, ParameterType type, String description) {
- super();
- this.name = name;
- this.typology = type;
- this.description = description;
- }
-
- public String getName() {
- return name;
- }
-
- public void setName(String name) {
- this.name = name;
- }
-
- /**
- * @return the typology
- */
- public ParameterType getTypology() {
- return typology;
- }
-
- /**
- * @param typology
- * the typology to set
- */
- public void setTypology(ParameterType typology) {
- this.typology = typology;
- }
-
- /**
- * @return the description
- */
- public String getDescription() {
- return description;
- }
-
- /**
- * @param description
- * the description to set
- */
- public void setDescription(String description) {
- this.description = description;
- }
-
- /**
- *
- * @return value
- */
- public String getValue() {
- return value;
- }
-
- /**
- *
- * @param value
- * value
- */
- public void setValue(String value) {
- this.value = value;
- }
-
- @Override
- public String toString() {
- return "Parameter [name=" + name + ", description=" + description + ", typology=" + typology + ", value="
- + value + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/ParameterType.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/ParameterType.java
deleted file mode 100644
index 121ec94..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/ParameterType.java
+++ /dev/null
@@ -1,11 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.shared.parameters;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public enum ParameterType {
- OBJECT, TABULAR, FILE, ENUM, LIST, COLUMN, COLUMN_LIST, TABULAR_LIST, WKT, DATE, TIME;
-}
\ No newline at end of file
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/TabularListParameter.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/TabularListParameter.java
deleted file mode 100644
index a07908f..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/TabularListParameter.java
+++ /dev/null
@@ -1,103 +0,0 @@
-/**
- *
- */
-package org.gcube.portlets.user.dataminermanager.shared.parameters;
-
-import java.util.ArrayList;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class TabularListParameter extends Parameter {
-
- private static final long serialVersionUID = -1786477950530892502L;
- private String separator;
- private ArrayList templates = new ArrayList();
- private String defaultMimeType;
- private ArrayList supportedMimeTypes;
-
- // private List tableNames = new ArrayList();
-
- public TabularListParameter() {
- super();
- this.typology = ParameterType.TABULAR_LIST;
- }
-
- /**
- *
- * @param name
- * name
- * @param description
- * description
- * @param separator
- * separator
- * @param defaultMimeType
- * default mime type
- * @param supportedMimeTypes
- * supported mime types
- */
- public TabularListParameter(String name, String description, String separator, String defaultMimeType,
- ArrayList supportedMimeTypes) {
- super(name, ParameterType.TABULAR_LIST, description);
- this.separator = separator;
- this.defaultMimeType = defaultMimeType;
- this.supportedMimeTypes = supportedMimeTypes;
- }
-
- /**
- * @return the separator
- */
- public String getSeparator() {
- return separator;
- }
-
- /**
- * @param templates
- * the templates to set
- */
- public void setTemplates(ArrayList templates) {
- this.templates = templates;
- }
-
- /**
- * @return the templates
- */
- public ArrayList getTemplates() {
- return templates;
- }
-
- public void addTemplate(String template) {
- templates.add(template);
- }
-
- public String getDefaultMimeType() {
- return defaultMimeType;
- }
-
- public void setDefaultMimeType(String defaultMimeType) {
- this.defaultMimeType = defaultMimeType;
- }
-
- public ArrayList getSupportedMimeTypes() {
- return supportedMimeTypes;
- }
-
- public void setSupportedMimeTypes(ArrayList supportedMimeTypes) {
- this.supportedMimeTypes = supportedMimeTypes;
- }
-
- public void setSeparator(String separator) {
- this.separator = separator;
- }
-
- @Override
- public String toString() {
- return "TabularListParameter [value=" + value + ", separator=" + separator + ", templates=" + templates
- + ", defaultMimeType=" + defaultMimeType + ", supportedMimeTypes=" + supportedMimeTypes + ", name="
- + name + ", description=" + description + ", typology=" + typology + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/TabularParameter.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/TabularParameter.java
deleted file mode 100644
index 8865991..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/TabularParameter.java
+++ /dev/null
@@ -1,114 +0,0 @@
-/**
- *
- */
-package org.gcube.portlets.user.dataminermanager.shared.parameters;
-
-import java.util.ArrayList;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class TabularParameter extends Parameter {
-
- private static final long serialVersionUID = 8038591467145151553L;
- private ArrayList templates = new ArrayList();
- private String defaultMimeType;
- private ArrayList supportedMimeTypes;
-
- /**
- *
- */
- public TabularParameter() {
- super();
- this.typology = ParameterType.TABULAR;
- }
-
- /**
- *
- * @param name
- * name
- * @param description
- * description
- * @param tableName
- * table name
- * @param defaultMimeType
- * default mime type
- * @param supportedMimeTypes
- * supported mime types
- */
- public TabularParameter(String name, String description, String tableName, String defaultMimeType,
- ArrayList supportedMimeTypes) {
- super(name, ParameterType.TABULAR, description);
- this.value = tableName;
- this.templates = null;
- this.defaultMimeType = defaultMimeType;
- this.supportedMimeTypes = supportedMimeTypes;
- }
-
- /**
- *
- * @param name
- * name
- * @param description
- * description
- * @param tableName
- * table name
- * @param templates
- * templates
- * @param defaultMimeType
- * default mime type
- * @param supportedMimeTypes
- * supported mime type
- */
- public TabularParameter(String name, String description, String tableName, ArrayList templates,
- String defaultMimeType, ArrayList supportedMimeTypes) {
- super(name, ParameterType.TABULAR, description);
- this.value = tableName;
- this.templates = templates;
- this.defaultMimeType = defaultMimeType;
- this.supportedMimeTypes = supportedMimeTypes;
- }
-
- public String getTableName() {
- return value;
- }
-
- public void setTableName(String tableName) {
- this.value = tableName;
- }
-
- public ArrayList getTemplates() {
- return templates;
- }
-
- public void setTemplates(ArrayList templates) {
- this.templates = templates;
- }
-
- public String getDefaultMimeType() {
- return defaultMimeType;
- }
-
- public void setDefaultMimeType(String defaultMimeType) {
- this.defaultMimeType = defaultMimeType;
- }
-
- public ArrayList getSupportedMimeTypes() {
- return supportedMimeTypes;
- }
-
- public void setSupportedMimeTypes(ArrayList supportedMimeTypes) {
- this.supportedMimeTypes = supportedMimeTypes;
- }
-
- @Override
- public String toString() {
- return "TabularParameter [tableName=" + value + ", templates=" + templates + ", defaultMimeType="
- + defaultMimeType + ", supportedMimeTypes=" + supportedMimeTypes + ", name=" + name + ", description="
- + description + ", typology=" + typology + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/TimeParameter.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/TimeParameter.java
deleted file mode 100644
index fc1f1e2..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/TimeParameter.java
+++ /dev/null
@@ -1,60 +0,0 @@
-/**
- *
- */
-package org.gcube.portlets.user.dataminermanager.shared.parameters;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class TimeParameter extends Parameter {
-
- private static final long serialVersionUID = 1673874854501249519L;
- private String defaultValue;
-
- /**
- *
- */
- public TimeParameter() {
- super();
- this.typology = ParameterType.TIME;
- }
-
- /**
- *
- * @param name
- * name
- * @param description
- * description
- * @param defaultValue
- * default value
- */
- public TimeParameter(String name, String description, String defaultValue) {
- super(name, ParameterType.TIME, description);
- this.defaultValue = defaultValue;
- }
-
- /**
- * @return the default value
- */
- public String getDefaultValue() {
- return defaultValue;
- }
-
- /**
- * @param defaultValue
- * the default value to set
- */
- public void setDefaultValue(String defaultValue) {
- this.defaultValue = defaultValue;
- }
-
- @Override
- public String toString() {
- return "TimeParameter [defaultValue=" + defaultValue + ", value=" + value + ", name=" + name + ", description="
- + description + ", typology=" + typology + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/WKTGeometryType.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/WKTGeometryType.java
deleted file mode 100644
index 02bb3c9..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/WKTGeometryType.java
+++ /dev/null
@@ -1,62 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.shared.parameters;
-
-import java.util.Arrays;
-import java.util.List;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public enum WKTGeometryType {
- Point("Point"), LineString("LineString"), Polygon("Polygon"), Circle("Circle"), Triangle("Triangle"), Square(
- "Square"), Pentagon("Pentagon"), Hexagon("Hexagon"), Box("Box");
-
- /**
- *
- * @param label
- * label
- */
- private WKTGeometryType(final String label) {
- this.label = label;
- }
-
- private final String label;
-
- @Override
- public String toString() {
- return label;
- }
-
- public String getLabel() {
- return label;
- }
-
- public String getId() {
- return name();
- }
-
- /**
- *
- * @param label
- * label
- * @return wkt geometry type
- */
- public static WKTGeometryType getFromLabel(String label) {
- if (label == null || label.isEmpty())
- return null;
-
- for (WKTGeometryType type : values()) {
- if (type.label.compareToIgnoreCase(label) == 0) {
- return type;
- }
- }
- return null;
- }
-
- public static List asList() {
- List list = Arrays.asList(values());
- return list;
- }
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/WKTParameter.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/WKTParameter.java
deleted file mode 100644
index 93ca640..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/parameters/WKTParameter.java
+++ /dev/null
@@ -1,81 +0,0 @@
-/**
- *
- */
-package org.gcube.portlets.user.dataminermanager.shared.parameters;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class WKTParameter extends Parameter {
-
- private static final long serialVersionUID = 1673874854501249519L;
- private WKTGeometryType wktGeometryType;
- private String defaultValue;
-
- /**
- *
- */
- public WKTParameter() {
- super();
- this.typology = ParameterType.WKT;
- }
-
- /**
- *
- * @param name
- * name
- * @param description
- * description
- * @param wktGeometryType
- * WKT Geometry type
- * @param defaultValue
- * default value
- */
- public WKTParameter(String name, String description, WKTGeometryType wktGeometryType, String defaultValue) {
- super(name, ParameterType.WKT, description);
- this.wktGeometryType = wktGeometryType;
- this.defaultValue = defaultValue;
- }
-
- /**
- * @return the default value
- */
- public String getDefaultValue() {
- return defaultValue;
- }
-
- /**
- * @param defaultValue
- * the default value to set
- */
- public void setDefaultValue(String defaultValue) {
- this.defaultValue = defaultValue;
- }
-
- /**
- *
- * @return the WKT Geometry type
- */
- public WKTGeometryType getWktGeometryType() {
- return wktGeometryType;
- }
-
- /**
- *
- * @param wktGeometryType
- * set the WKT Geometry type
- */
- public void setWktGeometryType(WKTGeometryType wktGeometryType) {
- this.wktGeometryType = wktGeometryType;
- }
-
- @Override
- public String toString() {
- return "WKTParameter [wktGeometryType=" + wktGeometryType + ", defaultValue=" + defaultValue + ", value="
- + value + ", name=" + name + ", description=" + description + ", typology=" + typology + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/process/ComputationStatus.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/process/ComputationStatus.java
deleted file mode 100644
index bfc4e04..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/process/ComputationStatus.java
+++ /dev/null
@@ -1,128 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.shared.process;
-
-import java.io.Serializable;
-import java.util.Date;
-
-import org.gcube.portlets.user.dataminermanager.shared.exception.ServiceException;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class ComputationStatus implements Serializable {
-
- private static final long serialVersionUID = -1943128398882978439L;
-
- public enum Status {
- ACCEPTED, RUNNING, COMPLETE, FAILED, CANCELLED;
- };
-
- private double percentage;
- private Status status;
- private Date endDate;
- private String message;
- private ServiceException error;
-
- public ComputationStatus() {
- this.status = Status.ACCEPTED;
- }
-
- public ComputationStatus(double percentage) {
- super();
- this.percentage = percentage;
- this.status = Status.RUNNING;
- }
-
- public ComputationStatus(Status status, double percentage) {
- super();
- this.percentage = percentage;
- this.status = status;
- }
-
- public ComputationStatus(ServiceException error) {
- super();
- this.percentage = 100f;
- this.status = Status.FAILED;
- this.error = error;
- }
-
- public boolean isComplete() {
- return this.status == Status.COMPLETE;
- }
-
- public boolean isFailed() {
- return this.status == Status.FAILED;
- }
-
- public boolean isRunning() {
- return this.status == Status.RUNNING;
- }
-
- public boolean isAccepted() {
- return this.status == Status.ACCEPTED;
- }
-
- public boolean isCancelled() {
- return this.status == Status.CANCELLED;
- }
-
- public boolean isPaused() {
- return false;
- // return this.status == Status.FAILED;
- }
-
- public boolean isTerminated() {
- return status == Status.COMPLETE || status == Status.FAILED
- || status == Status.CANCELLED;
- }
-
- public double getPercentage() {
- return percentage;
- }
-
- public void setPercentage(double percentage) {
- this.percentage = percentage;
- }
-
- public Status getStatus() {
- return status;
- }
-
- public void setStatus(Status status) {
- this.status = status;
- }
-
- public Date getEndDate() {
- return endDate;
- }
-
- public void setEndDate(Date endDate) {
- this.endDate = endDate;
- }
-
- public String getMessage() {
- return message;
- }
-
- public void setMessage(String message) {
- this.message = message;
- }
-
- public ServiceException getError() {
- return error;
- }
-
- public void setError(ServiceException error) {
- this.error = error;
- }
-
- @Override
- public String toString() {
- return "ComputationStatus [percentage=" + percentage + ", status="
- + status + ", endDate=" + endDate + ", message=" + message
- + ", error=" + error + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/process/Operator.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/process/Operator.java
deleted file mode 100644
index ac4119d..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/process/Operator.java
+++ /dev/null
@@ -1,258 +0,0 @@
-/**
- *
- */
-package org.gcube.portlets.user.dataminermanager.shared.process;
-
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.List;
-
-import org.gcube.portlets.user.dataminermanager.shared.StringUtil;
-import org.gcube.portlets.user.dataminermanager.shared.parameters.Parameter;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class Operator implements Serializable, Comparable {
-
- private static final long serialVersionUID = -4084498655645951188L;
- private String id;
- private String name;
- private String briefDescription;
- private String description;
- private OperatorCategory category;
- private List operatorParameters = new ArrayList();
- private boolean hasImage = false;
-
- /**
- *
- */
- public Operator() {
- super();
- }
-
- /**
- *
- * @param id
- * id
- * @param briefDescription
- * brief description
- * @param description
- * description
- * @param category
- * category
- */
- public Operator(String id, String briefDescription, String description, OperatorCategory category) {
- super();
- this.id = id;
- if (id != null)
- this.name = StringUtil.getCapitalWords(id);
- this.briefDescription = briefDescription;
- this.description = description;
- this.category = category;
- }
-
- /**
- *
- * @param id
- * id
- * @param briefDescription
- * brief description
- * @param description
- * description
- * @param category
- * category
- * @param hasImage
- * true if has image
- */
- public Operator(String id, String briefDescription, String description, OperatorCategory category,
- boolean hasImage) {
- super();
- this.id = id;
- if (id != null)
- this.name = StringUtil.getCapitalWords(id);
- this.briefDescription = briefDescription;
- this.description = description;
- this.category = category;
- this.hasImage = hasImage;
- }
-
- /**
- *
- * @param id
- * id
- * @param name
- * name
- * @param briefDescription
- * brief description
- * @param description
- * description
- * @param category
- * category
- */
- public Operator(String id, String name, String briefDescription, String description, OperatorCategory category) {
- super();
- this.id = id;
- if (name != null)
- this.name = StringUtil.getCapitalWords(name);
- this.briefDescription = briefDescription;
- this.description = description;
- this.category = category;
- }
-
- /**
- *
- * @param id
- * id
- * @param name
- * name
- * @param briefDescription
- * brief description
- * @param description
- * description
- * @param category
- * category
- * @param operatorParameters
- * operator parameters
- * @param hasImage
- * true if has image
- */
- public Operator(String id, String name, String briefDescription, String description, OperatorCategory category,
- List operatorParameters, boolean hasImage) {
- super();
- this.id = id;
- if (name != null)
- this.name = StringUtil.getCapitalWords(name);
- this.briefDescription = briefDescription;
- this.description = description;
- this.category = category;
- this.operatorParameters = operatorParameters;
- this.hasImage = hasImage;
- }
-
- /**
- * @return the id
- */
- public String getId() {
- return id;
- }
-
- /**
- * @param id
- * the id to set
- */
- public void setId(String id) {
- this.id = id;
- }
-
- /**
- * @return the briefDescription
- */
- public String getBriefDescription() {
- return briefDescription;
- }
-
- /**
- * @param briefDescription
- * the briefDescription to set
- */
- public void setBriefDescription(String briefDescription) {
- this.briefDescription = briefDescription;
- }
-
- /**
- * @return the description
- */
- public String getDescription() {
- return description;
- }
-
- /**
- * @param description
- * the description to set
- */
- public void setDescription(String description) {
- this.description = description;
- }
-
- /**
- * @return the category
- */
- public OperatorCategory getCategory() {
- return category;
- }
-
- /**
- * @param category
- * the category to set
- */
- public void setCategory(OperatorCategory category) {
- this.category = category;
- }
-
- /**
- * @return the operatorParameters
- */
- public List getOperatorParameters() {
- return operatorParameters;
- }
-
- /**
- * @param operatorParameters
- * the operatorParameters to set
- */
- public void setOperatorParameters(List operatorParameters) {
- this.operatorParameters = operatorParameters;
- }
-
- public void addOperatorParameter(Parameter operatorParameter) {
- this.operatorParameters.add(operatorParameter);
- }
-
- /**
- * @param name
- * the name to set
- */
- public void setName(String name) {
- this.name = name;
- }
-
- /**
- * @return the name
- */
- public String getName() {
- return name;
- }
-
- public boolean hasImage() {
- return hasImage;
- }
-
- /**
- * @param hasImage
- * the hasImage to set
- */
- public void setHasImage(boolean hasImage) {
- this.hasImage = hasImage;
- }
-
- public Operator clone() {
- return new Operator(id, name, briefDescription, description, category,
- new ArrayList(operatorParameters), hasImage);
- }
-
- @Override
- public String toString() {
- return "Operator [id=" + id + ", name=" + name + ", briefDescription=" + briefDescription + ", description="
- + description + ", operatorParameters=" + operatorParameters + ", hasImage=" + hasImage + "]";
- }
-
- @Override
- public int compareTo(Operator o) {
- return id.compareTo(o.getId());
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/process/OperatorCategory.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/process/OperatorCategory.java
deleted file mode 100644
index aa1ec38..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/process/OperatorCategory.java
+++ /dev/null
@@ -1,247 +0,0 @@
-/**
- *
- */
-package org.gcube.portlets.user.dataminermanager.shared.process;
-
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class OperatorCategory implements Serializable, Comparable {
-
- private static final long serialVersionUID = 7511425996378626337L;
- private String id;
- private String name;
- private String briefDescription;
- private String description;
- private List operators = new ArrayList();
- private boolean hasImage = false;
-
- /**
- *
- */
- public OperatorCategory() {
- super();
- }
-
- /**
- *
- * @param id
- * id
- * @param briefDescription
- * brief description
- * @param description
- * description
- */
- public OperatorCategory(String id, String briefDescription, String description) {
- super();
- this.id = id;
- setNameFromId();
- this.briefDescription = briefDescription;
- this.description = description;
- }
-
- /**
- *
- * @param id
- * id
- * @param briefDescription
- * brief description
- * @param description
- * description
- * @param hasImage
- * true if has image
- */
- public OperatorCategory(String id, String briefDescription, String description, boolean hasImage) {
- super();
- this.id = id;
- setNameFromId();
- this.briefDescription = briefDescription;
- this.description = description;
- this.hasImage = hasImage;
- }
-
- /**
- *
- * @param id
- * id
- * @param briefDescription
- * brief description
- * @param description
- * description
- * @param operators
- * list of operator
- */
- public OperatorCategory(String id, String briefDescription, String description, List operators) {
- super();
- this.id = id;
- setNameFromId();
- this.briefDescription = briefDescription;
- this.description = description;
- this.operators = operators;
- }
-
- /**
- *
- * @param id
- * id
- * @param name
- * name
- * @param briefDescription
- * brief description
- * @param description
- * description
- * @param operators
- * list of operator
- */
- public OperatorCategory(String id, String name, String briefDescription, String description,
- List operators) {
- super();
- this.id = id;
- this.name = name;
- this.briefDescription = briefDescription;
- this.description = description;
- this.operators = operators;
- }
-
- /**
- * @return the id
- */
- public String getId() {
- return id;
- }
-
- /**
- * @param id
- * the id to set
- */
- public void setId(String id) {
- this.id = id;
- }
-
- /**
- * @return the briefDescription
- */
- public String getBriefDescription() {
- return briefDescription;
- }
-
- /**
- * @param briefDescription
- * the briefDescription to set
- */
- public void setBriefDescription(String briefDescription) {
- this.briefDescription = briefDescription;
- }
-
- /**
- * @return the description
- */
- public String getDescription() {
- return description;
- }
-
- /**
- * @param description
- * the description to set
- */
- public void setDescription(String description) {
- this.description = description;
- }
-
- /**
- * @return the operators
- */
- public List getOperators() {
- return operators;
- }
-
- /**
- * @param operators
- * list of operator
- */
- public void setOperators(List operators) {
- this.operators = operators;
- }
-
- public void addOperator(Operator operator) {
- this.operators.add(operator);
- }
-
- private void setNameFromId() {
- if (id != null) {
- String name = "";
-
- boolean precUnderscore = true;
- for (int i = 0; i < id.length(); i++) {
- char c = id.charAt(i);
-
- if (c == '_') {
- precUnderscore = true;
- name += " ";
- } else {
- name += (precUnderscore ? Character.toUpperCase(c) : Character.toLowerCase(c));
- if (precUnderscore == true)
- precUnderscore = false;
- }
- }
- this.name = name;
- }
- }
-
- /**
- * @param name
- * the name to set
- */
- public void setName(String name) {
- this.name = name;
- }
-
- /**
- * @return the name
- */
- public String getName() {
- return name;
- }
-
- /**
- *
- * @return true if has image
- */
- public boolean hasImage() {
- return hasImage;
- }
-
- /**
- * @param hasImage
- * the hasImage to set
- */
- public void setHasImage(boolean hasImage) {
- this.hasImage = hasImage;
- }
-
- public OperatorCategory clone() {
- OperatorCategory op = new OperatorCategory(id, name, briefDescription, description,
- new ArrayList(operators));
- op.setHasImage(hasImage);
- return op;
- }
-
- @Override
- public String toString() {
- return "OperatorCategory [id=" + id + ", name=" + name + ", briefDescription=" + briefDescription
- + ", description=" + description + ", operators=" + operators + ", hasImage=" + hasImage + "]";
- }
-
- @Override
- public int compareTo(OperatorCategory o) {
- return id.compareTo(o.getId());
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/process/OperatorsClassification.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/process/OperatorsClassification.java
deleted file mode 100644
index 1b3673a..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/process/OperatorsClassification.java
+++ /dev/null
@@ -1,127 +0,0 @@
-/**
- *
- */
-package org.gcube.portlets.user.dataminermanager.shared.process;
-
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class OperatorsClassification implements Serializable {
-
- private static final long serialVersionUID = 7347445659350838584L;
- private String name;
- private List operatorCategories = new ArrayList();
- private List operators = new ArrayList();
-
- public OperatorsClassification() {
- super();
- }
-
- /**
- *
- * @param name
- * name
- */
- public OperatorsClassification(String name) {
- super();
- this.name = name;
- }
-
- /**
- *
- * @param name
- * name
- * @param operatorCategories
- * categories
- * @param operators
- * list of operator
- */
- public OperatorsClassification(String name, List operatorCategories, List operators) {
- this(name);
- this.operatorCategories = operatorCategories;
- this.operators = operators;
- }
-
- /**
- *
- * @return list of category
- */
- public List getOperatorCategories() {
- return operatorCategories;
- }
-
- /**
- *
- * @param operatorCategories
- * list of category
- */
- public void setOperatorCategories(List operatorCategories) {
- this.operatorCategories = operatorCategories;
- }
-
- /**
- * @return list of operator
- */
- public List getOperators() {
- return operators;
- }
-
- /**
- * @param operators
- * the operators to set
- */
- public void setOperators(List operators) {
- this.operators = operators;
- }
-
- public Operator getOperatorById(String id) {
- if (id == null)
- return null;
- Operator operator = null;
- for (Operator op : operators)
- if (op.getId().contentEquals(id)) {
- operator = op;
- break;
- }
- return operator;
- }
-
- public OperatorCategory getCategoryById(String id) {
- OperatorCategory category = null;
- for (OperatorCategory cat : operatorCategories)
- if (cat.getId().contentEquals(id)) {
- category = cat;
- break;
- }
- return category;
- }
-
- /**
- * @return the name
- */
- public String getName() {
- return name;
- }
-
- /**
- * @param name
- * the name to set
- */
- public void setName(String name) {
- this.name = name;
- }
-
- @Override
- public String toString() {
- return "OperatorsClassification [name=" + name + ", operatorCategories=" + operatorCategories + ", operators="
- + operators + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/process/TemplateDescriptor.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/process/TemplateDescriptor.java
deleted file mode 100644
index 3c77e07..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/process/TemplateDescriptor.java
+++ /dev/null
@@ -1,98 +0,0 @@
-/**
- *
- */
-package org.gcube.portlets.user.dataminermanager.shared.process;
-
-import java.util.HashMap;
-import java.util.Map;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class TemplateDescriptor {
-
- public static TemplateDescriptor descriptors[] = { new TemplateDescriptor("HCAF", "HCAF Data Set", ""),
- new TemplateDescriptor("OCCURRENCE_SPECIES", "Occurrence Species Data Set", ""),
- new TemplateDescriptor("OCCURRENCE_AQUAMAPS", "Occurrence Aquamaps", ""),
- new TemplateDescriptor("HSPEN", "HSPEN Data Set", ""),
- new TemplateDescriptor("HSPEC", "HSPEC Data Set", ""),
- new TemplateDescriptor("CLUSTER", "Cluster Data Set", ""),
- new TemplateDescriptor("TRAININGSET", "Neural Network Training Set", ""),
- new TemplateDescriptor("TESTSET", "Neural Network Test Set", ""),
- new TemplateDescriptor("GENERIC", "Generic Data set", ""),
- new TemplateDescriptor("MINMAXLAT", "Min Max Lat Data Set", ""),
- new TemplateDescriptor("TIMESERIES", "time Series Data Set", ""), };
-
- public static String[] s = new String[] { "" };
- public static Map map;
- static {
- map = new HashMap();
- map.put("HCAF", new String[][] { { "csquarecode", "string" }, { "depthmin", "real" }, { "depthmax", "real" },
- { "depthmean", "real" }, { "depthsd", "real" }, { "sstanmean", "real" }, { "sstansd", "real" },
- { "sstmnmax", "real" }, { "sstmnmin", "real" }, { "sstmnrange", "real" }, { "sbtanmean", "real" },
- { "salinitymean", "real" }, { "salinitysd", "real" }, { "salinitymax", "real" },
- { "salinitymin", "real" }, { "salinitybmean", "real" }, { "primprodmean", "integer" },
- { "iceconann", "real" }, { "iceconspr", "real" }, { "iceconsum", "real" }, { "iceconfal", "real" },
- { "iceconwin", "real" }, { "faoaream", "integer" }, { "eezall", "string" }, { "lme", "integer" },
- { "landdist", "integer" }, { "oceanarea", "real" }, { "centerlat", "real" },
- { "centerlong", "real" }, });
- }
- public static TemplateDescriptor defaultDescriptor = descriptors[0];
-
- // public enum Template {
- // HCAF,
- // OCCURRENCE_SPECIES,
- // OCCURRENCE_AQUAMAPS,
- // HSPEN,
- // HSPEC,
- // CLUSTER,
- // TRAININGSET,
- // TESTSET,
- // GENERIC,
- // MINMAXLAT,
- // TIMESERIES,
- // }
-
- private String id, title, description;
-
- /**
- *
- * @param id
- * id
- * @param title
- * title
- * @param description
- * description
- */
- public TemplateDescriptor(String id, String title, String description) {
- super();
- this.id = id;
- this.title = title;
- this.description = description;
- }
-
- /**
- * @return the id
- */
- public String getId() {
- return id;
- }
-
- /**
- * @return the description
- */
- public String getDescription() {
- return description;
- }
-
- /**
- *
- * @return the title
- */
- public String getTitle() {
- return title;
- }
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/workspace/Computations.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/workspace/Computations.java
deleted file mode 100644
index 52906f4..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/workspace/Computations.java
+++ /dev/null
@@ -1,38 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.shared.workspace;
-
-import java.io.Serializable;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class Computations implements Serializable {
-
- private static final long serialVersionUID = 7375248981531583668L;
- private ItemDescription folder;
-
- public Computations() {
- super();
- }
-
- public Computations(ItemDescription folder) {
- super();
- this.folder = folder;
- }
-
- public ItemDescription getFolder() {
- return folder;
- }
-
- public void setFolder(ItemDescription folder) {
- this.folder = folder;
- }
-
- @Override
- public String toString() {
- return "Computations [folder=" + folder + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/workspace/DataMinerWorkArea.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/workspace/DataMinerWorkArea.java
deleted file mode 100644
index 171ceac..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/workspace/DataMinerWorkArea.java
+++ /dev/null
@@ -1,92 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.shared.workspace;
-
-import java.io.Serializable;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class DataMinerWorkArea implements Serializable {
-
- private static final long serialVersionUID = -7906477664944910362L;
- private ItemDescription dataMinerWorkAreaFolder;
- private InputDataSets inputDataSets;
- private OutputDataSets outputDataSets;
- private Computations computations;
-
- public DataMinerWorkArea() {
- super();
- }
-
- /**
- *
- * @param dataMinerWorkAreaFolder
- * DataMiner work area folder
- */
- public DataMinerWorkArea(ItemDescription dataMinerWorkAreaFolder) {
- super();
- this.dataMinerWorkAreaFolder = dataMinerWorkAreaFolder;
-
- }
-
- /**
- *
- * @param dataMinerWorkAreaFolder
- * DataMiner work area folder
- * @param inputDataSets
- * input data sets
- * @param outputDataSets
- * output data sets
- * @param computations
- * computations
- */
- public DataMinerWorkArea(ItemDescription dataMinerWorkAreaFolder, InputDataSets inputDataSets,
- OutputDataSets outputDataSets, Computations computations) {
- super();
- this.dataMinerWorkAreaFolder = dataMinerWorkAreaFolder;
- this.inputDataSets = inputDataSets;
- this.outputDataSets = outputDataSets;
- this.computations = computations;
- }
-
- public ItemDescription getDataMinerWorkAreaFolder() {
- return dataMinerWorkAreaFolder;
- }
-
- public void setDataMinerWorkAreaFolder(ItemDescription dataMinerWorkAreaFolder) {
- this.dataMinerWorkAreaFolder = dataMinerWorkAreaFolder;
- }
-
- public InputDataSets getInputDataSets() {
- return inputDataSets;
- }
-
- public void setInputDataSets(InputDataSets inputDataSets) {
- this.inputDataSets = inputDataSets;
- }
-
- public OutputDataSets getOutputDataSets() {
- return outputDataSets;
- }
-
- public void setOutputDataSets(OutputDataSets outputDataSets) {
- this.outputDataSets = outputDataSets;
- }
-
- public Computations getComputations() {
- return computations;
- }
-
- public void setComputations(Computations computations) {
- this.computations = computations;
- }
-
- @Override
- public String toString() {
- return "DataMinerWorkArea [dataMinerWorkAreaFolder=" + dataMinerWorkAreaFolder + ", inputDataSets="
- + inputDataSets + ", outputDataSets=" + outputDataSets + ", computations=" + computations + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/workspace/InputDataSets.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/workspace/InputDataSets.java
deleted file mode 100644
index 5449853..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/workspace/InputDataSets.java
+++ /dev/null
@@ -1,38 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.shared.workspace;
-
-import java.io.Serializable;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class InputDataSets implements Serializable {
- private static final long serialVersionUID = -4408116083736005844L;
-
- private ItemDescription folder;
-
- public InputDataSets() {
- super();
- }
-
- public InputDataSets(ItemDescription folder) {
- super();
- this.folder = folder;
- }
-
- public ItemDescription getFolder() {
- return folder;
- }
-
- public void setFolder(ItemDescription folder) {
- this.folder = folder;
- }
-
- @Override
- public String toString() {
- return "ImportedData [folder=" + folder + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/workspace/ItemDescription.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/workspace/ItemDescription.java
deleted file mode 100644
index 739b8dc..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/workspace/ItemDescription.java
+++ /dev/null
@@ -1,108 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.shared.workspace;
-
-import java.io.Serializable;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class ItemDescription implements Serializable {
-
- private static final long serialVersionUID = -6624452446980057923L;
-
- private String id;
- private String name;
- private String owner;
- private String path;
- private String type;
- private String publicLink;
-
- public ItemDescription() {
- super();
- }
-
- public ItemDescription(String id, String name, String owner, String path, String type) {
- super();
- this.id = id;
- this.name = name;
- this.owner = owner;
- this.path = path;
- this.type = type;
- }
-
- public String getId() {
- return id;
- }
-
- public void setId(String id) {
- this.id = id;
- }
-
- public String getName() {
- return name;
- }
-
- public void setName(String name) {
- this.name = name;
- }
-
- public String getOwner() {
- return owner;
- }
-
- public void setOwner(String owner) {
- this.owner = owner;
- }
-
- public String getPath() {
- return path;
- }
-
- public void setPath(String path) {
- this.path = path;
- }
-
- public String getType() {
- return type;
- }
-
- public void setType(String type) {
- this.type = type;
- }
-
- public String getPublicLink() {
- return publicLink;
- }
-
- public void setPublicLink(String publicLink) {
- this.publicLink = publicLink;
- }
-
- /**
- * Compare basic information with another ItemDescription not null
- *
- * @param itemDescription
- * item description
- * @return boolean true if match
- *
- */
- public boolean compareInfo(ItemDescription itemDescription) {
- if (itemDescription != null && id.compareTo(itemDescription.getId()) == 0
- && name.compareTo(itemDescription.getName()) == 0 && owner.compareTo(itemDescription.getOwner()) == 0
- && path.compareTo(itemDescription.getPath()) == 0 && type.compareTo(itemDescription.getType()) == 0) {
- return true;
- } else {
- return false;
- }
-
- }
-
- @Override
- public String toString() {
- return "ItemDescription [id=" + id + ", name=" + name + ", owner=" + owner + ", path=" + path + ", type=" + type
- + ", publicLink=" + publicLink + "]";
- }
-
-}
diff --git a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/workspace/OutputDataSets.java b/src/main/java/org/gcube/portlets/user/dataminermanager/shared/workspace/OutputDataSets.java
deleted file mode 100644
index 0c317ba..0000000
--- a/src/main/java/org/gcube/portlets/user/dataminermanager/shared/workspace/OutputDataSets.java
+++ /dev/null
@@ -1,38 +0,0 @@
-package org.gcube.portlets.user.dataminermanager.shared.workspace;
-
-import java.io.Serializable;
-
-/**
- *
- * @author Giancarlo Panichi
- *
- *
- */
-public class OutputDataSets implements Serializable {
- private static final long serialVersionUID = -8235652292513149983L;
-
- private ItemDescription folder;
-
- public OutputDataSets() {
- super();
- }
-
- public OutputDataSets(ItemDescription folder) {
- super();
- this.folder = folder;
- }
-
- public ItemDescription getFolder() {
- return folder;
- }
-
- public void setFolder(ItemDescription folder) {
- this.folder = folder;
- }
-
- @Override
- public String toString() {
- return "ComputedData [folder=" + folder + "]";
- }
-
-}
diff --git a/src/main/resources/org/gcube/portlets/user/dataminermanager/dataminermanager.gwt.xml b/src/main/resources/org/gcube/portlets/user/dataminermanager/dataminermanager.gwt.xml
index 141ea72..2602154 100644
--- a/src/main/resources/org/gcube/portlets/user/dataminermanager/dataminermanager.gwt.xml
+++ b/src/main/resources/org/gcube/portlets/user/dataminermanager/dataminermanager.gwt.xml
@@ -7,27 +7,29 @@
-
-
+
+
-
+
-
+
+
+
+
-
+
-
-
+
+
@@ -38,19 +40,20 @@
-
-
-
-
+ /> -->
+
+
-
-
+
+
+
+
diff --git a/src/test/java/org/gcube/portlets/user/dataminermanager/TestDataMinerService.java b/src/test/java/org/gcube/portlets/user/dataminermanager/TestDataMinerService.java
index 246e5b8..8b22897 100644
--- a/src/test/java/org/gcube/portlets/user/dataminermanager/TestDataMinerService.java
+++ b/src/test/java/org/gcube/portlets/user/dataminermanager/TestDataMinerService.java
@@ -20,8 +20,8 @@ import junit.framework.TestCase;
import org.apache.commons.codec.binary.Base64;
import org.gcube.common.authorization.library.provider.UserInfo;
-import org.gcube.portlets.user.dataminermanager.server.is.InformationSystemUtils;
-import org.gcube.portlets.user.dataminermanager.server.util.ServiceCredentials;
+import org.gcube.data.analysis.dataminermanagercl.server.is.InformationSystemUtils;
+import org.gcube.data.analysis.dataminermanagercl.server.util.ServiceCredentials;
import org.gcube.portlets.user.dataminermanager.shared.Constants;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;