ref 8471:TDM - DataMiner Manager - Support Java 8 compatibility
https://support.d4science.org/issues/8471 Updated to support Java 8 compatibility git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/widgets/data-miner-manager-widget@148452 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
2ed09d9df1
commit
5801474f2a
18
.classpath
18
.classpath
|
@ -1,20 +1,28 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<classpath>
|
<classpath>
|
||||||
<classpathentry kind="src" output="target/data-miner-manager-widget-1.0.0-SNAPSHOT/WEB-INF/classes" path="src/main/java">
|
<classpathentry kind="src" output="target/data-miner-manager-widget-1.1.0-SNAPSHOT/WEB-INF/classes" path="src/main/java">
|
||||||
<attributes>
|
<attributes>
|
||||||
<attribute name="optional" value="true"/>
|
<attribute name="optional" value="true"/>
|
||||||
<attribute name="maven.pomderived" value="true"/>
|
<attribute name="maven.pomderived" value="true"/>
|
||||||
</attributes>
|
</attributes>
|
||||||
</classpathentry>
|
</classpathentry>
|
||||||
<classpathentry including="**/*.java" kind="src" path="src/main/resources"/>
|
<classpathentry excluding="**" kind="src" output="target/data-miner-manager-widget-1.1.0-SNAPSHOT/WEB-INF/classes" path="src/main/resources">
|
||||||
|
<attributes>
|
||||||
|
<attribute name="maven.pomderived" value="true"/>
|
||||||
|
</attributes>
|
||||||
|
</classpathentry>
|
||||||
<classpathentry kind="src" output="target/test-classes" path="src/test/java">
|
<classpathentry kind="src" output="target/test-classes" path="src/test/java">
|
||||||
<attributes>
|
<attributes>
|
||||||
<attribute name="optional" value="true"/>
|
<attribute name="optional" value="true"/>
|
||||||
<attribute name="maven.pomderived" value="true"/>
|
<attribute name="maven.pomderived" value="true"/>
|
||||||
</attributes>
|
</attributes>
|
||||||
</classpathentry>
|
</classpathentry>
|
||||||
<classpathentry including="**/*.java" kind="src" output="target/test-classes" path="src/test/resources"/>
|
<classpathentry excluding="**" kind="src" output="target/test-classes" path="src/test/resources">
|
||||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7">
|
<attributes>
|
||||||
|
<attribute name="maven.pomderived" value="true"/>
|
||||||
|
</attributes>
|
||||||
|
</classpathentry>
|
||||||
|
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8">
|
||||||
<attributes>
|
<attributes>
|
||||||
<attribute name="maven.pomderived" value="true"/>
|
<attribute name="maven.pomderived" value="true"/>
|
||||||
</attributes>
|
</attributes>
|
||||||
|
@ -25,5 +33,5 @@
|
||||||
</attributes>
|
</attributes>
|
||||||
</classpathentry>
|
</classpathentry>
|
||||||
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
|
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
|
||||||
<classpathentry kind="output" path="target/data-miner-manager-widget-1.0.0-SNAPSHOT/WEB-INF/classes"/>
|
<classpathentry kind="output" path="target/data-miner-manager-widget-1.1.0-SNAPSHOT/WEB-INF/classes"/>
|
||||||
</classpath>
|
</classpath>
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
eclipse.preferences.version=1
|
eclipse.preferences.version=1
|
||||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
|
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
|
||||||
org.eclipse.jdt.core.compiler.compliance=1.7
|
org.eclipse.jdt.core.compiler.compliance=1.8
|
||||||
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
|
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
|
||||||
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
|
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
|
||||||
org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning
|
org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning
|
||||||
org.eclipse.jdt.core.compiler.source=1.7
|
org.eclipse.jdt.core.compiler.source=1.8
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
<wb-resource deploy-path="/" source-path="/src/main/webapp" tag="defaultRootSource"/>
|
<wb-resource deploy-path="/" source-path="/src/main/webapp" tag="defaultRootSource"/>
|
||||||
<wb-resource deploy-path="/WEB-INF/classes" source-path="/src/main/java"/>
|
<wb-resource deploy-path="/WEB-INF/classes" source-path="/src/main/java"/>
|
||||||
<wb-resource deploy-path="/WEB-INF/classes" source-path="/src/main/resources"/>
|
<wb-resource deploy-path="/WEB-INF/classes" source-path="/src/main/resources"/>
|
||||||
|
<wb-resource deploy-path="/WEB-INF/classes" source-path="/src/test/resources"/>
|
||||||
<property name="java-output-path" value="/data-miner-manager/target/data-miner-manager-1.2.0-SNAPSHOT/WEB-INF/classes"/>
|
<property name="java-output-path" value="/data-miner-manager/target/data-miner-manager-1.2.0-SNAPSHOT/WEB-INF/classes"/>
|
||||||
<property name="context-root" value="data-miner-manager-widget"/>
|
<property name="context-root" value="data-miner-manager-widget"/>
|
||||||
</wb-module>
|
</wb-module>
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<faceted-project>
|
<faceted-project>
|
||||||
<fixed facet="wst.jsdt.web"/>
|
<fixed facet="wst.jsdt.web"/>
|
||||||
<installed facet="java" version="1.7"/>
|
<installed facet="java" version="1.8"/>
|
||||||
<installed facet="jst.web" version="3.0"/>
|
<installed facet="jst.web" version="3.0"/>
|
||||||
<installed facet="wst.jsdt.web" version="1.0"/>
|
<installed facet="wst.jsdt.web" version="1.0"/>
|
||||||
</faceted-project>
|
</faceted-project>
|
||||||
|
|
|
@ -1,4 +1,8 @@
|
||||||
<ReleaseNotes>
|
<ReleaseNotes>
|
||||||
|
<Changeset component="org.gcube.portlets.widgets.data-miner-manager-widget.1-1-0"
|
||||||
|
date="2017-06-12">
|
||||||
|
<Change>Support Java 8 compatibility [ticket #8471]</Change>
|
||||||
|
</Changeset>
|
||||||
<Changeset component="org.gcube.portlets.widgets.data-miner-manager-widget.1-0-0"
|
<Changeset component="org.gcube.portlets.widgets.data-miner-manager-widget.1-0-0"
|
||||||
date="2017-03-31">
|
date="2017-03-31">
|
||||||
<Change>First release</Change>
|
<Change>First release</Change>
|
||||||
|
|
11
pom.xml
11
pom.xml
|
@ -12,7 +12,7 @@
|
||||||
|
|
||||||
<groupId>org.gcube.portlets.widgets</groupId>
|
<groupId>org.gcube.portlets.widgets</groupId>
|
||||||
<artifactId>data-miner-manager-widget</artifactId>
|
<artifactId>data-miner-manager-widget</artifactId>
|
||||||
<version>1.0.0-SNAPSHOT</version>
|
<version>1.1.0-SNAPSHOT</version>
|
||||||
|
|
||||||
<name>data-miner-manager-widget</name>
|
<name>data-miner-manager-widget</name>
|
||||||
<description>data-miner-manager-widget offers a unique access to perform data mining and statistical operations on heterogeneous data</description>
|
<description>data-miner-manager-widget offers a unique access to perform data mining and statistical operations on heterogeneous data</description>
|
||||||
|
@ -40,8 +40,9 @@
|
||||||
<configDirectory>config</configDirectory>
|
<configDirectory>config</configDirectory>
|
||||||
|
|
||||||
|
|
||||||
<!-- Java Version -->
|
<!-- Java -->
|
||||||
<javaVersion>1.7</javaVersion>
|
<maven.compiler.source>1.7</maven.compiler.source>
|
||||||
|
<maven.compiler.target>1.8</maven.compiler.target>
|
||||||
|
|
||||||
<!-- GWT configuration -->
|
<!-- GWT configuration -->
|
||||||
<gwtVersion>2.6.1</gwtVersion>
|
<gwtVersion>2.6.1</gwtVersion>
|
||||||
|
@ -433,8 +434,8 @@
|
||||||
<artifactId>maven-compiler-plugin</artifactId>
|
<artifactId>maven-compiler-plugin</artifactId>
|
||||||
<version>2.3.2</version>
|
<version>2.3.2</version>
|
||||||
<configuration>
|
<configuration>
|
||||||
<source>${javaVersion}</source>
|
<source>${maven.compiler.source}</source>
|
||||||
<target>${javaVersion}</target>
|
<target>${maven.compiler.target}</target>
|
||||||
</configuration>
|
</configuration>
|
||||||
</plugin>
|
</plugin>
|
||||||
|
|
||||||
|
|
|
@ -49,8 +49,8 @@ import com.sencha.gxt.widget.core.client.event.HideEvent.HideHandler;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class DataMinerManagerController {
|
public class DataMinerManagerController {
|
||||||
|
|
|
@ -13,8 +13,8 @@ import com.sencha.gxt.widget.core.client.Window;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class DataMinerManagerDialog extends Window implements HasExternalExecutionEventHandler {
|
public class DataMinerManagerDialog extends Window implements HasExternalExecutionEventHandler {
|
||||||
|
|
|
@ -23,8 +23,8 @@ import com.sencha.gxt.widget.core.client.container.SimpleContainer;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class DataMinerManagerPanel extends ContentPanel {
|
public class DataMinerManagerPanel extends ContentPanel {
|
||||||
|
|
|
@ -21,8 +21,8 @@ import com.google.gwt.user.client.ui.Image;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class Header extends HorizontalPanel {
|
public class Header extends HorizontalPanel {
|
||||||
|
|
|
@ -22,8 +22,8 @@ import com.sencha.gxt.widget.core.client.container.VerticalLayoutContainer.Verti
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class HomePanel extends SimpleContainer {
|
public class HomePanel extends SimpleContainer {
|
||||||
|
|
|
@ -15,8 +15,8 @@ import com.sencha.gxt.widget.core.client.container.Viewport.ViewportAppearance;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi"
|
* @author Giancarlo Panichi
|
||||||
* <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class PortalViewport extends SimpleContainer {
|
public class PortalViewport extends SimpleContainer {
|
||||||
|
|
|
@ -8,8 +8,8 @@ import com.google.gwt.event.shared.SimpleEventBus;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class EventBusProvider {
|
public class EventBusProvider {
|
||||||
|
|
|
@ -14,8 +14,8 @@ import com.sencha.gxt.widget.core.client.form.TextField;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ComputationValueFileListPanel extends SimpleContainer {
|
public class ComputationValueFileListPanel extends SimpleContainer {
|
||||||
|
|
|
@ -14,8 +14,8 @@ import com.sencha.gxt.widget.core.client.event.SelectEvent;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ComputationValueFilePanel extends SimpleContainer {
|
public class ComputationValueFilePanel extends SimpleContainer {
|
||||||
|
|
|
@ -14,8 +14,8 @@ import com.sencha.gxt.widget.core.client.event.SelectEvent;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ComputationValueImagePanel extends SimpleContainer {
|
public class ComputationValueImagePanel extends SimpleContainer {
|
||||||
|
|
|
@ -50,8 +50,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ComputationsExecutedPanel extends FramedPanel {
|
public class ComputationsExecutedPanel extends FramedPanel {
|
||||||
|
|
|
@ -20,8 +20,8 @@ import com.sencha.gxt.widget.core.client.container.SimpleContainer;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ComputationsPanel extends SimpleContainer {
|
public class ComputationsPanel extends SimpleContainer {
|
||||||
|
|
|
@ -2,8 +2,8 @@ package org.gcube.portlets.widgets.dataminermanagerwidget.client.computations;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public enum ComputationsPropertiesType {
|
public enum ComputationsPropertiesType {
|
||||||
|
|
|
@ -26,8 +26,8 @@ import com.sencha.gxt.widget.core.client.form.TextField;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ComputationsViewerPanel extends FramedPanel {
|
public class ComputationsViewerPanel extends FramedPanel {
|
||||||
|
|
|
@ -3,8 +3,8 @@ package org.gcube.portlets.widgets.dataminermanagerwidget.client.custom;
|
||||||
/**
|
/**
|
||||||
* Fix for z-index bug between GXT3 and GXT2
|
* Fix for z-index bug between GXT3 and GXT2
|
||||||
*
|
*
|
||||||
* @author giancarlo email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class Gxt2ZIndexXDOM extends
|
public class Gxt2ZIndexXDOM extends
|
||||||
|
|
|
@ -5,8 +5,8 @@ import com.sencha.gxt.widget.core.client.ProgressBar;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class GreenProgressBar extends ProgressBar {
|
public class GreenProgressBar extends ProgressBar {
|
||||||
|
|
|
@ -19,8 +19,8 @@ import com.sencha.gxt.core.client.util.Format;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class GreenProgressBarAppearance implements ProgressBarAppearance {
|
public class GreenProgressBarAppearance implements ProgressBarAppearance {
|
||||||
|
|
|
@ -5,8 +5,8 @@ import com.sencha.gxt.widget.core.client.ProgressBar;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class OrangeProgressBar extends ProgressBar {
|
public class OrangeProgressBar extends ProgressBar {
|
||||||
|
|
|
@ -19,8 +19,8 @@ import com.sencha.gxt.core.client.util.Format;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class OrangeProgressBarAppearance implements ProgressBarAppearance {
|
public class OrangeProgressBarAppearance implements ProgressBarAppearance {
|
||||||
|
|
|
@ -5,8 +5,8 @@ import com.sencha.gxt.widget.core.client.ProgressBar;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class RedProgressBar extends ProgressBar {
|
public class RedProgressBar extends ProgressBar {
|
||||||
|
|
|
@ -19,8 +19,8 @@ import com.sencha.gxt.core.client.util.Format;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class RedProgressBarAppearance implements ProgressBarAppearance {
|
public class RedProgressBarAppearance implements ProgressBarAppearance {
|
||||||
|
|
|
@ -11,8 +11,8 @@ import com.sencha.gxt.widget.core.client.container.SimpleContainer;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class DataSpacePanel extends SimpleContainer {
|
public class DataSpacePanel extends SimpleContainer {
|
||||||
|
|
|
@ -2,8 +2,8 @@ package org.gcube.portlets.widgets.dataminermanagerwidget.client.dataspace;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public enum DataSpacePropertiesType {
|
public enum DataSpacePropertiesType {
|
||||||
|
|
|
@ -48,8 +48,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class InputDataSetsPanel extends FramedPanel {
|
public class InputDataSetsPanel extends FramedPanel {
|
||||||
|
|
|
@ -48,8 +48,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class OutputDataSetsPanel extends FramedPanel {
|
public class OutputDataSetsPanel extends FramedPanel {
|
||||||
|
|
|
@ -12,8 +12,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Cancel Computation Request Event
|
* Cancel Computation Request Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class CancelComputationExecutionRequestEvent
|
public class CancelComputationExecutionRequestEvent
|
||||||
|
|
|
@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Cancel Execution From Computations Request Event
|
* Cancel Execution From Computations Request Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class CancelExecutionFromComputationsRequestEvent
|
public class CancelExecutionFromComputationsRequestEvent
|
||||||
|
|
|
@ -12,8 +12,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Computation Data Event
|
* Computation Data Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ComputationDataEvent extends
|
public class ComputationDataEvent extends
|
||||||
|
|
|
@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Output Show Request Event
|
* Output Show Request Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ComputationDataRequestEvent
|
public class ComputationDataRequestEvent
|
||||||
|
|
|
@ -12,8 +12,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Computation Ready Event
|
* Computation Ready Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ComputationReadyEvent extends
|
public class ComputationReadyEvent extends
|
||||||
|
|
|
@ -13,8 +13,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Data Miner Work Area Event
|
* Data Miner Work Area Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class DataMinerWorkAreaEvent extends
|
public class DataMinerWorkAreaEvent extends
|
||||||
|
|
|
@ -12,8 +12,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Data Miner Work Area Request Event
|
* Data Miner Work Area Request Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class DataMinerWorkAreaRequestEvent
|
public class DataMinerWorkAreaRequestEvent
|
||||||
|
|
|
@ -12,8 +12,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Delete Item Request Event
|
* Delete Item Request Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class DeleteItemRequestEvent extends
|
public class DeleteItemRequestEvent extends
|
||||||
|
|
|
@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* External Execution Event
|
* External Execution Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ExternalExecutionEvent extends
|
public class ExternalExecutionEvent extends
|
||||||
|
|
|
@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Start Computation Execution Request Event
|
* Start Computation Execution Request Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ExternalExecutionRequestEvent extends
|
public class ExternalExecutionRequestEvent extends
|
||||||
|
|
|
@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Menu Event
|
* Menu Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class MenuEvent extends
|
public class MenuEvent extends
|
||||||
|
|
|
@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Menu Event
|
* Menu Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class MenuSwitchEvent extends
|
public class MenuSwitchEvent extends
|
||||||
|
|
|
@ -12,8 +12,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Operators Classification Event
|
* Operators Classification Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class OperatorsClassificationEvent
|
public class OperatorsClassificationEvent
|
||||||
|
|
|
@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Operators Classification Request Event
|
* Operators Classification Request Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class OperatorsClassificationRequestEvent
|
public class OperatorsClassificationRequestEvent
|
||||||
|
|
|
@ -12,8 +12,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Output Data Event
|
* Output Data Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class OutputDataEvent extends
|
public class OutputDataEvent extends
|
||||||
|
|
|
@ -12,8 +12,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Output Data Request Event
|
* Output Data Request Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class OutputDataRequestEvent extends
|
public class OutputDataRequestEvent extends
|
||||||
|
|
|
@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Refresh DataMiner Work Area Event
|
* Refresh DataMiner Work Area Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class RefreshDataMinerWorkAreaEvent extends
|
public class RefreshDataMinerWorkAreaEvent extends
|
||||||
|
|
|
@ -12,8 +12,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Resubmit Computation Execution Event
|
* Resubmit Computation Execution Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ResubmitComputationExecutionEvent
|
public class ResubmitComputationExecutionEvent
|
||||||
|
|
|
@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Resubmit Computation Execution Request Event
|
* Resubmit Computation Execution Request Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ResubmitComputationExecutionRequestEvent
|
public class ResubmitComputationExecutionRequestEvent
|
||||||
|
|
|
@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Session Expired Event
|
* Session Expired Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class SessionExpiredEvent extends GwtEvent<SessionExpiredEvent.SessionExpiredEventHandler> {
|
public class SessionExpiredEvent extends GwtEvent<SessionExpiredEvent.SessionExpiredEventHandler> {
|
||||||
|
|
|
@ -12,8 +12,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Start Computation Execution Event
|
* Start Computation Execution Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class StartComputationExecutionEvent
|
public class StartComputationExecutionEvent
|
||||||
|
|
|
@ -12,8 +12,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Start Computation Execution Request Event
|
* Start Computation Execution Request Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class StartComputationExecutionRequestEvent
|
public class StartComputationExecutionRequestEvent
|
||||||
|
|
|
@ -12,8 +12,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* TabularFldChangeEvent
|
* TabularFldChangeEvent
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class TabularFldChangeEvent extends
|
public class TabularFldChangeEvent extends
|
||||||
|
|
|
@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Tabular Resource Info Event
|
* Tabular Resource Info Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class TabularResourceInfoEvent extends
|
public class TabularResourceInfoEvent extends
|
||||||
|
|
|
@ -9,8 +9,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* Tabular Resource Info Request Event
|
* Tabular Resource Info Request Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class TabularResourceInfoRequestEvent
|
public class TabularResourceInfoRequestEvent
|
||||||
|
|
|
@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* User Interface State Event
|
* User Interface State Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class UIStateEvent extends GwtEvent<UIStateEvent.UIStateEventHandler> {
|
public class UIStateEvent extends GwtEvent<UIStateEvent.UIStateEventHandler> {
|
||||||
|
|
|
@ -12,8 +12,8 @@ import com.google.gwt.event.shared.HasHandlers;
|
||||||
* WPS Menu Event
|
* WPS Menu Event
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class WPSMenuEvent extends
|
public class WPSMenuEvent extends
|
||||||
|
|
|
@ -25,8 +25,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ComputationExecutionPanel extends FramedPanel {
|
public class ComputationExecutionPanel extends FramedPanel {
|
||||||
|
|
|
@ -34,8 +34,8 @@ import com.sencha.gxt.widget.core.client.container.VerticalLayoutContainer.Verti
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ComputationOutputPanel extends SimpleContainer {
|
public class ComputationOutputPanel extends SimpleContainer {
|
||||||
|
|
|
@ -28,8 +28,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ComputationPanel extends FramedPanel implements HasComputationReadyEventHandler
|
public class ComputationPanel extends FramedPanel implements HasComputationReadyEventHandler
|
||||||
|
|
|
@ -44,8 +44,8 @@ import com.sencha.gxt.widget.core.client.form.FormPanel;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ComputationParametersPanel extends SimpleContainer {
|
public class ComputationParametersPanel extends SimpleContainer {
|
||||||
|
|
|
@ -33,8 +33,8 @@ import com.sencha.gxt.widget.core.client.info.Info;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ComputationStatusPanel extends SimpleContainer {
|
public class ComputationStatusPanel extends SimpleContainer {
|
||||||
|
@ -49,6 +49,7 @@ public class ComputationStatusPanel extends SimpleContainer {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
* @param operatorName operator name
|
||||||
*/
|
*/
|
||||||
public ComputationStatusPanel(String operatorName) {
|
public ComputationStatusPanel(String operatorName) {
|
||||||
super();
|
super();
|
||||||
|
|
|
@ -10,8 +10,8 @@ import com.sencha.gxt.widget.core.client.form.TextArea;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class EquivalentRequestDialog extends Dialog {
|
public class EquivalentRequestDialog extends Dialog {
|
||||||
|
|
|
@ -11,8 +11,8 @@ import com.sencha.gxt.widget.core.client.container.SimpleContainer;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ExperimentPanel extends SimpleContainer implements
|
public class ExperimentPanel extends SimpleContainer implements
|
||||||
|
|
|
@ -22,8 +22,8 @@ import com.sencha.gxt.widget.core.client.tips.ToolTipConfig;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class OperatorCategoryPanel extends SimpleContainer {
|
public class OperatorCategoryPanel extends SimpleContainer {
|
||||||
|
@ -38,14 +38,14 @@ public class OperatorCategoryPanel extends SimpleContainer {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @param handler
|
* @param handler operator panel handler
|
||||||
* @param cat
|
* @param operatorCategory operator category
|
||||||
*/
|
*/
|
||||||
public OperatorCategoryPanel(OperatorsPanelHandler handler,
|
public OperatorCategoryPanel(OperatorsPanelHandler handler,
|
||||||
OperatorCategory cat) {
|
OperatorCategory operatorCategory) {
|
||||||
super();
|
super();
|
||||||
this.handler = handler;
|
this.handler = handler;
|
||||||
this.category = cat;
|
this.category = operatorCategory;
|
||||||
create();
|
create();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
package org.gcube.portlets.widgets.dataminermanagerwidget.client.experiments;
|
package org.gcube.portlets.widgets.dataminermanagerwidget.client.experiments;
|
||||||
|
|
||||||
|
|
||||||
import org.gcube.data.analysis.dataminermanagercl.shared.process.Operator;
|
import org.gcube.data.analysis.dataminermanagercl.shared.process.Operator;
|
||||||
import org.gcube.portlets.widgets.dataminermanagerwidget.client.DataMinerManagerPanel;
|
import org.gcube.portlets.widgets.dataminermanagerwidget.client.DataMinerManagerPanel;
|
||||||
|
|
||||||
|
@ -19,7 +18,7 @@ import com.sencha.gxt.widget.core.client.tips.ToolTipConfig;
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi
|
* @author Giancarlo Panichi
|
||||||
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class OperatorPanel extends SimpleContainer {
|
public class OperatorPanel extends SimpleContainer {
|
||||||
|
@ -36,7 +35,9 @@ public class OperatorPanel extends SimpleContainer {
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @param operator
|
* @param operator
|
||||||
|
* operator
|
||||||
* @param handler
|
* @param handler
|
||||||
|
* operator panel handler
|
||||||
*/
|
*/
|
||||||
public OperatorPanel(Operator operator, OperatorsPanelHandler handler) {
|
public OperatorPanel(Operator operator, OperatorsPanelHandler handler) {
|
||||||
super();
|
super();
|
||||||
|
@ -56,7 +57,7 @@ public class OperatorPanel extends SimpleContainer {
|
||||||
public void onClick(ClickEvent event) {
|
public void onClick(ClickEvent event) {
|
||||||
event.stopPropagation();
|
event.stopPropagation();
|
||||||
handler.addOperator(OperatorPanel.this, operator);
|
handler.addOperator(OperatorPanel.this, operator);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}, ClickEvent.getType());
|
}, ClickEvent.getType());
|
||||||
|
@ -64,31 +65,30 @@ public class OperatorPanel extends SimpleContainer {
|
||||||
titleHtml = new HTML(operator.getName());
|
titleHtml = new HTML(operator.getName());
|
||||||
titleHtml.addStyleName("operatorPanel-title");
|
titleHtml.addStyleName("operatorPanel-title");
|
||||||
|
|
||||||
HTML descriptionHtml = new HTML(Format.ellipse(operator.getBriefDescription(),OPERATOR_BRIEF_DESCRIPTION_LENGHT));
|
HTML descriptionHtml = new HTML(
|
||||||
|
Format.ellipse(operator.getBriefDescription(), OPERATOR_BRIEF_DESCRIPTION_LENGHT));
|
||||||
descriptionHtml.addStyleName("operatorPanel-briefDescription");
|
descriptionHtml.addStyleName("operatorPanel-briefDescription");
|
||||||
|
|
||||||
vert=new VerticalLayoutContainer();
|
vert = new VerticalLayoutContainer();
|
||||||
|
|
||||||
vert.add(titleHtml, new VerticalLayoutData(1, -1, new Margins(0)));
|
vert.add(titleHtml, new VerticalLayoutData(1, -1, new Margins(0)));
|
||||||
vert.add(descriptionHtml, new VerticalLayoutData(1, -1, new Margins(0)));
|
vert.add(descriptionHtml, new VerticalLayoutData(1, -1, new Margins(0)));
|
||||||
add(vert);
|
add(vert);
|
||||||
|
|
||||||
ToolTipConfig tooltipConfig = createToolTip(operator);
|
ToolTipConfig tooltipConfig = createToolTip(operator);
|
||||||
setToolTipConfig(tooltipConfig);
|
setToolTipConfig(tooltipConfig);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @return
|
* @return operator
|
||||||
*/
|
*/
|
||||||
public Operator getOperator() {
|
public Operator getOperator() {
|
||||||
return operator;
|
return operator;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
private ToolTipConfig createToolTip(Operator op) {
|
private ToolTipConfig createToolTip(Operator op) {
|
||||||
ToolTipConfig tooltipConfig = new ToolTipConfig();
|
ToolTipConfig tooltipConfig = new ToolTipConfig();
|
||||||
tooltipConfig.setTitleHtml("<br> " + op.getName());
|
tooltipConfig.setTitleHtml("<br> " + op.getName());
|
||||||
|
@ -96,32 +96,26 @@ public class OperatorPanel extends SimpleContainer {
|
||||||
tooltipConfig.setMouseOffsetY(0);
|
tooltipConfig.setMouseOffsetY(0);
|
||||||
tooltipConfig.setAnchor(Side.LEFT);
|
tooltipConfig.setAnchor(Side.LEFT);
|
||||||
tooltipConfig.setDismissDelay(5000);
|
tooltipConfig.setDismissDelay(5000);
|
||||||
tooltipConfig.setBodyHtml(getTooltipTemplate(GWT.getModuleBaseURL(),
|
tooltipConfig.setBodyHtml(
|
||||||
op.getId(), op.hasImage(), op.getDescription()));
|
getTooltipTemplate(GWT.getModuleBaseURL(), op.getId(), op.hasImage(), op.getDescription()));
|
||||||
// config.setCloseable(true);
|
// config.setCloseable(true);
|
||||||
tooltipConfig.setMaxWidth(TOOLTIP_WIDTH);
|
tooltipConfig.setMaxWidth(TOOLTIP_WIDTH);
|
||||||
return tooltipConfig;
|
return tooltipConfig;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
private String getTooltipTemplate(String base, String id, boolean hasImage, String description) {
|
||||||
*
|
String image = DataMinerManagerPanel.resources.operatorsDefaultImage().getSafeUri().asString();
|
||||||
* @param base
|
|
||||||
* @param id
|
String template = "<div class='categoryItemTooltip'>" + "<img src='" + image + "' >"
|
||||||
* @param hasImage
|
+ Format.ellipse(description, TOOLTIP_DESCRIPTION_LENGHT) + "</div>";
|
||||||
* @param description
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
private String getTooltipTemplate(String base, String id, boolean hasImage,
|
|
||||||
String description) {
|
|
||||||
String image=DataMinerManagerPanel.resources.operatorsDefaultImage().getSafeUri().asString();
|
|
||||||
|
|
||||||
String template = "<div class='categoryItemTooltip'>" + "<img src='"
|
|
||||||
+ image +"' >" + Format.ellipse(description, TOOLTIP_DESCRIPTION_LENGHT)
|
|
||||||
+ "</div>";
|
|
||||||
|
|
||||||
return template;
|
return template;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param isSelect set if is selected
|
||||||
|
*/
|
||||||
public void toggleSelected(boolean isSelect) {
|
public void toggleSelected(boolean isSelect) {
|
||||||
if (isSelect)
|
if (isSelect)
|
||||||
this.addStyleName("operatorPanel-selected");
|
this.addStyleName("operatorPanel-selected");
|
||||||
|
@ -130,8 +124,11 @@ public class OperatorPanel extends SimpleContainer {
|
||||||
this.removeStyleName("operatorPanel-selected");
|
this.removeStyleName("operatorPanel-selected");
|
||||||
// titleHtml.removeStyleName("operatorPanel-title-selected");
|
// titleHtml.removeStyleName("operatorPanel-title-selected");
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setAsTheDefaultOperator(){
|
/**
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
public void setAsTheDefaultOperator() {
|
||||||
handler.addOperator(OperatorPanel.this, operator);
|
handler.addOperator(OperatorPanel.this, operator);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -42,8 +42,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class OperatorsPanel extends FramedPanel {
|
public class OperatorsPanel extends FramedPanel {
|
||||||
|
@ -70,9 +70,10 @@ public class OperatorsPanel extends FramedPanel {
|
||||||
private View view = null;
|
private View view = null;
|
||||||
private String currentClassificationName = Constants.UserClassificationName;
|
private String currentClassificationName = Constants.UserClassificationName;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
* @param handler
|
||||||
|
* operators panel handler
|
||||||
*/
|
*/
|
||||||
public OperatorsPanel(OperatorsPanelHandler handler) {
|
public OperatorsPanel(OperatorsPanelHandler handler) {
|
||||||
super();
|
super();
|
||||||
|
@ -91,81 +92,67 @@ public class OperatorsPanel extends FramedPanel {
|
||||||
}
|
}
|
||||||
|
|
||||||
private void bind() {
|
private void bind() {
|
||||||
EventBusProvider.INSTANCE
|
EventBusProvider.INSTANCE.addHandler(OperatorsClassificationEvent.TYPE,
|
||||||
.addHandler(
|
new OperatorsClassificationEvent.OperatorsClassificationEventHandler() {
|
||||||
OperatorsClassificationEvent.TYPE,
|
|
||||||
new OperatorsClassificationEvent.OperatorsClassificationEventHandler() {
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onOperatorsClassification(
|
public void onOperatorsClassification(OperatorsClassificationEvent event) {
|
||||||
OperatorsClassificationEvent event) {
|
Log.debug("OperatorsPanel catch OperatorsClassificationEvent: " + event);
|
||||||
Log.debug("OperatorsPanel catch OperatorsClassificationEvent: "
|
manageOperatorsClassificationEvent(event);
|
||||||
+ event);
|
}
|
||||||
manageOperatorsClassificationEvent(event);
|
});
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void manageOperatorsClassificationEvent(
|
private void manageOperatorsClassificationEvent(OperatorsClassificationEvent event) {
|
||||||
OperatorsClassificationEvent event) {
|
if (event.getOperatorsClassificationRequestType().compareTo(OperatorsClassificationRequestType.ByName) == 0) {
|
||||||
if (event.getOperatorsClassificationRequestType().compareTo(
|
if (currentClassificationName.compareTo(event.getClassificationName()) == 0) {
|
||||||
OperatorsClassificationRequestType.ByName) == 0) {
|
|
||||||
if (currentClassificationName.compareTo(event
|
|
||||||
.getClassificationName()) == 0) {
|
|
||||||
waitMessage(false);
|
waitMessage(false);
|
||||||
if (event.getOperatorsClassification() != null) {
|
if (event.getOperatorsClassification() != null) {
|
||||||
operatorsClassification = event
|
operatorsClassification = event.getOperatorsClassification();
|
||||||
.getOperatorsClassification();
|
|
||||||
operators.clear();
|
operators.clear();
|
||||||
operators.addAll(event.getOperatorsClassification()
|
operators.addAll(event.getOperatorsClassification().getOperators());
|
||||||
.getOperators());
|
|
||||||
String operatorId = event.getOperatorId();
|
String operatorId = event.getOperatorId();
|
||||||
|
|
||||||
Log.debug("ShowCategoriesList");
|
Log.debug("ShowCategoriesList");
|
||||||
List<OperatorCategoryPanel> categoryPanels = mapCategoriesPanels
|
List<OperatorCategoryPanel> categoryPanels = mapCategoriesPanels.get(currentClassificationName);
|
||||||
.get(currentClassificationName);
|
|
||||||
if (categoryPanels == null) {
|
if (categoryPanels == null) {
|
||||||
categoryPanels = new ArrayList<OperatorCategoryPanel>();
|
categoryPanels = new ArrayList<OperatorCategoryPanel>();
|
||||||
if (operatorsClassification != null) {
|
if (operatorsClassification != null) {
|
||||||
for (OperatorCategory cat : operatorsClassification
|
for (OperatorCategory cat : operatorsClassification.getOperatorCategories()) {
|
||||||
.getOperatorCategories()) {
|
categoryPanels.add(new OperatorCategoryPanel(handler, cat));
|
||||||
categoryPanels.add(new OperatorCategoryPanel(
|
|
||||||
handler, cat));
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
mapCategoriesPanels.put(currentClassificationName,
|
mapCategoriesPanels.put(currentClassificationName, categoryPanels);
|
||||||
categoryPanels);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
v.clear();
|
v.clear();
|
||||||
for (OperatorCategoryPanel panel : categoryPanels){
|
for (OperatorCategoryPanel panel : categoryPanels) {
|
||||||
v.add(panel);
|
v.add(panel);
|
||||||
|
|
||||||
}
|
}
|
||||||
view = View.CATEGORIES;
|
view = View.CATEGORIES;
|
||||||
if(operatorId!=null&&!operatorId.isEmpty()){
|
if (operatorId != null && !operatorId.isEmpty()) {
|
||||||
OperatorCategory operatorCategoryDefault=null;
|
OperatorCategory operatorCategoryDefault = null;
|
||||||
Operator operatorDefault=null;
|
Operator operatorDefault = null;
|
||||||
for(Operator op:operators){
|
for (Operator op : operators) {
|
||||||
if(op.getId().compareTo(operatorId)==0){
|
if (op.getId().compareTo(operatorId) == 0) {
|
||||||
operatorDefault=op;
|
operatorDefault = op;
|
||||||
operatorCategoryDefault=op.getCategory();
|
operatorCategoryDefault = op.getCategory();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(operatorCategoryDefault!=null){
|
if (operatorCategoryDefault != null) {
|
||||||
for (OperatorCategoryPanel opCategoryPanel : categoryPanels){
|
for (OperatorCategoryPanel opCategoryPanel : categoryPanels) {
|
||||||
if(opCategoryPanel.getCategory().compareTo(operatorCategoryDefault)==0){
|
if (opCategoryPanel.getCategory().compareTo(operatorCategoryDefault) == 0) {
|
||||||
opCategoryPanel.setOperatorDefault(operatorDefault);
|
opCategoryPanel.setOperatorDefault(operatorDefault);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
forceLayout();
|
forceLayout();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -188,8 +175,7 @@ public class OperatorsPanel extends FramedPanel {
|
||||||
OperatorsClassificationRequestEvent operatorsClassificationRequestEvent = new OperatorsClassificationRequestEvent(
|
OperatorsClassificationRequestEvent operatorsClassificationRequestEvent = new OperatorsClassificationRequestEvent(
|
||||||
currentClassificationName, true);
|
currentClassificationName, true);
|
||||||
Log.debug("OperatorsPanel fire: " + operatorsClassificationRequestEvent);
|
Log.debug("OperatorsPanel fire: " + operatorsClassificationRequestEvent);
|
||||||
EventBusProvider.INSTANCE
|
EventBusProvider.INSTANCE.fireEvent(operatorsClassificationRequestEvent);
|
||||||
.fireEvent(operatorsClassificationRequestEvent);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -201,8 +187,7 @@ public class OperatorsPanel extends FramedPanel {
|
||||||
final StoreFilterField<String> filterField = new StoreFilterField<String>() {
|
final StoreFilterField<String> filterField = new StoreFilterField<String>() {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected boolean doSelect(Store<String> store, String parent,
|
protected boolean doSelect(Store<String> store, String parent, String item, String filter) {
|
||||||
String item, String filter) {
|
|
||||||
Log.debug("StoreFilterField: " + item + " " + filter);
|
Log.debug("StoreFilterField: " + item + " " + filter);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -227,18 +212,16 @@ public class OperatorsPanel extends FramedPanel {
|
||||||
filterField.setWidth(100);
|
filterField.setWidth(100);
|
||||||
|
|
||||||
TextButton showAllOperatorsButton = new TextButton();
|
TextButton showAllOperatorsButton = new TextButton();
|
||||||
showAllOperatorsButton.setIcon(DataMinerManagerPanel.resources
|
showAllOperatorsButton.setIcon(DataMinerManagerPanel.resources.sortAscending());
|
||||||
.sortAscending());
|
showAllOperatorsButton.addSelectHandler(new SelectEvent.SelectHandler() {
|
||||||
showAllOperatorsButton
|
|
||||||
.addSelectHandler(new SelectEvent.SelectHandler() {
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onSelect(SelectEvent event) {
|
public void onSelect(SelectEvent event) {
|
||||||
filterField.clear();
|
filterField.clear();
|
||||||
showAllOperatorsList();
|
showAllOperatorsList();
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
showAllOperatorsButton.setToolTip(SHOW_ALL_OPERATORS_TOOLTIP);
|
showAllOperatorsButton.setToolTip(SHOW_ALL_OPERATORS_TOOLTIP);
|
||||||
|
|
||||||
TextButton showCategoriesButton = new TextButton();
|
TextButton showCategoriesButton = new TextButton();
|
||||||
|
@ -255,18 +238,15 @@ public class OperatorsPanel extends FramedPanel {
|
||||||
|
|
||||||
showCategoriesButton.setToolTip(SHOW_CATEGORIES_TOOLTIP);
|
showCategoriesButton.setToolTip(SHOW_CATEGORIES_TOOLTIP);
|
||||||
|
|
||||||
final TextButton btnMenuPerspective = new TextButton(
|
final TextButton btnMenuPerspective = new TextButton(currentClassificationName);
|
||||||
currentClassificationName);
|
btnMenuPerspective.setIcon(DataMinerManagerPanel.resources.userPerspective());
|
||||||
btnMenuPerspective
|
|
||||||
.setIcon(DataMinerManagerPanel.resources.userPerspective());
|
|
||||||
|
|
||||||
Menu menuPerspective = new Menu();
|
Menu menuPerspective = new Menu();
|
||||||
|
|
||||||
for (final String perspectiveName : Constants.ClassificationNames) {
|
for (final String perspectiveName : Constants.ClassificationNames) {
|
||||||
final ImageResource img = perspectiveName
|
final ImageResource img = perspectiveName.equals(Constants.UserClassificationName)
|
||||||
.equals(Constants.UserClassificationName) ? DataMinerManagerPanel.resources
|
? DataMinerManagerPanel.resources.userPerspective()
|
||||||
.userPerspective() : DataMinerManagerPanel.resources
|
: DataMinerManagerPanel.resources.computationPerspective();
|
||||||
.computationPerspective();
|
|
||||||
MenuItem perspectiveItem = new MenuItem(perspectiveName);
|
MenuItem perspectiveItem = new MenuItem(perspectiveName);
|
||||||
perspectiveItem.addSelectionHandler(new SelectionHandler<Item>() {
|
perspectiveItem.addSelectionHandler(new SelectionHandler<Item>() {
|
||||||
|
|
||||||
|
@ -306,16 +286,14 @@ public class OperatorsPanel extends FramedPanel {
|
||||||
List<String> ids = new ArrayList<String>();
|
List<String> ids = new ArrayList<String>();
|
||||||
for (Operator op : operators)
|
for (Operator op : operators)
|
||||||
// check for filtering and prevent duplicates
|
// check for filtering and prevent duplicates
|
||||||
if (op.getName().toLowerCase().contains(searchText.toLowerCase())
|
if (op.getName().toLowerCase().contains(searchText.toLowerCase()) && !ids.contains(op.getId())) {
|
||||||
&& !ids.contains(op.getId())) {
|
|
||||||
filteredOperators.add(op);
|
filteredOperators.add(op);
|
||||||
ids.add(op.getId());
|
ids.add(op.getId());
|
||||||
}
|
}
|
||||||
|
|
||||||
v.clear();
|
v.clear();
|
||||||
|
|
||||||
HTML html = new HTML("Filtered results <span class='counter'>("
|
HTML html = new HTML("Filtered results <span class='counter'>(" + filteredOperators.size() + " item"
|
||||||
+ filteredOperators.size() + " item"
|
|
||||||
+ (filteredOperators.size() == 1 ? "" : "s") + " found)</span>");
|
+ (filteredOperators.size() == 1 ? "" : "s") + " found)</span>");
|
||||||
html.addStyleName("filterResultText");
|
html.addStyleName("filterResultText");
|
||||||
v.add(html);
|
v.add(html);
|
||||||
|
@ -332,19 +310,15 @@ public class OperatorsPanel extends FramedPanel {
|
||||||
try {
|
try {
|
||||||
if (force || view != View.CATEGORIES) {
|
if (force || view != View.CATEGORIES) {
|
||||||
Log.debug("ShowCategoriesList");
|
Log.debug("ShowCategoriesList");
|
||||||
List<OperatorCategoryPanel> categoryPanels = mapCategoriesPanels
|
List<OperatorCategoryPanel> categoryPanels = mapCategoriesPanels.get(currentClassificationName);
|
||||||
.get(currentClassificationName);
|
|
||||||
if (categoryPanels == null) {
|
if (categoryPanels == null) {
|
||||||
categoryPanels = new ArrayList<OperatorCategoryPanel>();
|
categoryPanels = new ArrayList<OperatorCategoryPanel>();
|
||||||
if (operatorsClassification != null) {
|
if (operatorsClassification != null) {
|
||||||
for (OperatorCategory cat : operatorsClassification
|
for (OperatorCategory cat : operatorsClassification.getOperatorCategories()) {
|
||||||
.getOperatorCategories()) {
|
categoryPanels.add(new OperatorCategoryPanel(handler, cat));
|
||||||
categoryPanels.add(new OperatorCategoryPanel(
|
|
||||||
handler, cat));
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
mapCategoriesPanels.put(currentClassificationName,
|
mapCategoriesPanels.put(currentClassificationName, categoryPanels);
|
||||||
categoryPanels);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
v.clear();
|
v.clear();
|
||||||
|
@ -363,8 +337,7 @@ public class OperatorsPanel extends FramedPanel {
|
||||||
if (view != View.ALL) {
|
if (view != View.ALL) {
|
||||||
v.clear();
|
v.clear();
|
||||||
|
|
||||||
HTML html = new HTML("All Operators <span class='counter'>("
|
HTML html = new HTML("All Operators <span class='counter'>(" + operators.size() + " item"
|
||||||
+ operators.size() + " item"
|
|
||||||
+ (operators.size() == 1 ? "" : "s") + " found)</span>");
|
+ (operators.size() == 1 ? "" : "s") + " found)</span>");
|
||||||
html.addStyleName("filterResultText");
|
html.addStyleName("filterResultText");
|
||||||
v.add(html);
|
v.add(html);
|
||||||
|
|
|
@ -9,14 +9,14 @@ import org.gcube.data.analysis.dataminermanagercl.shared.process.Operator;
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi
|
* @author Giancarlo Panichi
|
||||||
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public interface OperatorsPanelHandler {
|
public interface OperatorsPanelHandler {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param operatorPanel
|
* @param operatorPanel operator panel
|
||||||
* @param operator
|
* @param operator operator
|
||||||
*/
|
*/
|
||||||
void addOperator(OperatorPanel operatorPanel, Operator operator);
|
void addOperator(OperatorPanel operatorPanel, Operator operator);
|
||||||
|
|
||||||
|
|
|
@ -16,8 +16,8 @@ import com.sencha.gxt.widget.core.client.TabPanel;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class WorkflowPanel extends TabPanel {
|
public class WorkflowPanel extends TabPanel {
|
||||||
|
|
|
@ -5,8 +5,8 @@ import com.sencha.gxt.widget.core.client.box.AutoProgressMessageBox;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author giancarlo email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class StatusMonitor extends AutoProgressMessageBox {
|
public class StatusMonitor extends AutoProgressMessageBox {
|
||||||
|
@ -18,8 +18,8 @@ public class StatusMonitor extends AutoProgressMessageBox {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @param headingHtml
|
* @param headingHtml head
|
||||||
* @param messageHtml
|
* @param messageHtml message
|
||||||
*/
|
*/
|
||||||
public StatusMonitor(SafeHtml headingHtml, SafeHtml messageHtml) {
|
public StatusMonitor(SafeHtml headingHtml, SafeHtml messageHtml) {
|
||||||
super(headingHtml, messageHtml);
|
super(headingHtml, messageHtml);
|
||||||
|
@ -28,7 +28,7 @@ public class StatusMonitor extends AutoProgressMessageBox {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @param headingHtml
|
* @param headingHtml head
|
||||||
*/
|
*/
|
||||||
public StatusMonitor(SafeHtml headingHtml) {
|
public StatusMonitor(SafeHtml headingHtml) {
|
||||||
super(headingHtml);
|
super(headingHtml);
|
||||||
|
@ -37,8 +37,8 @@ public class StatusMonitor extends AutoProgressMessageBox {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @param headingHtml
|
* @param headingHtml head
|
||||||
* @param messageHtml
|
* @param messageHtml message
|
||||||
*/
|
*/
|
||||||
public StatusMonitor(String headingHtml, String messageHtml) {
|
public StatusMonitor(String headingHtml, String messageHtml) {
|
||||||
super(headingHtml, messageHtml);
|
super(headingHtml, messageHtml);
|
||||||
|
@ -47,7 +47,7 @@ public class StatusMonitor extends AutoProgressMessageBox {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @param headingHtml
|
* @param headingHtml head
|
||||||
*/
|
*/
|
||||||
public StatusMonitor(String headingHtml) {
|
public StatusMonitor(String headingHtml) {
|
||||||
super(headingHtml);
|
super(headingHtml);
|
||||||
|
|
|
@ -3,7 +3,6 @@
|
||||||
*/
|
*/
|
||||||
package org.gcube.portlets.widgets.dataminermanagerwidget.client.parametersfield;
|
package org.gcube.portlets.widgets.dataminermanagerwidget.client.parametersfield;
|
||||||
|
|
||||||
|
|
||||||
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
|
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
|
||||||
|
|
||||||
import com.google.gwt.user.client.ui.Widget;
|
import com.google.gwt.user.client.ui.Widget;
|
||||||
|
@ -11,44 +10,47 @@ import com.google.gwt.user.client.ui.Widget;
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi
|
* @author Giancarlo Panichi
|
||||||
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public abstract class AbstractFld {
|
public abstract class AbstractFld {
|
||||||
|
|
||||||
protected Parameter parameter;
|
protected Parameter parameter;
|
||||||
public abstract String getValue();
|
|
||||||
|
public abstract String getValue();
|
||||||
|
|
||||||
public abstract Widget getWidget();
|
public abstract Widget getWidget();
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
|
* @param parameter
|
||||||
|
* parameter
|
||||||
*/
|
*/
|
||||||
public AbstractFld(Parameter parameter) {
|
public AbstractFld(Parameter parameter) {
|
||||||
this.parameter = parameter;
|
this.parameter = parameter;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return the operator
|
* @return the operator
|
||||||
*/
|
*/
|
||||||
public Parameter getParameter() {
|
public Parameter getParameter() {
|
||||||
return parameter;
|
return parameter;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param operator the operator to set
|
*
|
||||||
|
* @param parameter parameter
|
||||||
*/
|
*/
|
||||||
public void setParameter(Parameter parameter) {
|
public void setParameter(Parameter parameter) {
|
||||||
this.parameter = parameter;
|
this.parameter = parameter;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @return
|
* @return true if is valid
|
||||||
*/
|
*/
|
||||||
public boolean isValid() {
|
public boolean isValid() {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -19,8 +19,8 @@ import com.sencha.gxt.widget.core.client.form.SimpleComboBox;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class BooleanFld extends AbstractFld {
|
public class BooleanFld extends AbstractFld {
|
||||||
|
@ -30,6 +30,7 @@ public class BooleanFld extends AbstractFld {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param parameter
|
* @param parameter
|
||||||
|
* parameter
|
||||||
*/
|
*/
|
||||||
public BooleanFld(Parameter parameter) {
|
public BooleanFld(Parameter parameter) {
|
||||||
super(parameter);
|
super(parameter);
|
||||||
|
@ -48,14 +49,14 @@ public class BooleanFld extends AbstractFld {
|
||||||
listBox.setEditable(false);
|
listBox.setEditable(false);
|
||||||
listBox.setTriggerAction(TriggerAction.ALL);
|
listBox.setTriggerAction(TriggerAction.ALL);
|
||||||
|
|
||||||
if (p.getDefaultValue() != null&& !p.getDefaultValue().isEmpty()) {
|
if (p.getDefaultValue() != null && !p.getDefaultValue().isEmpty()) {
|
||||||
Boolean b=Boolean.valueOf(p.getDefaultValue());
|
Boolean b = Boolean.valueOf(p.getDefaultValue());
|
||||||
if(b){
|
if (b) {
|
||||||
listBox.setValue("true");
|
listBox.setValue("true");
|
||||||
} else {
|
} else {
|
||||||
listBox.setValue("false");
|
listBox.setValue("false");
|
||||||
}
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
listBox.setValue("false");
|
listBox.setValue("false");
|
||||||
}
|
}
|
||||||
|
@ -63,15 +64,12 @@ public class BooleanFld extends AbstractFld {
|
||||||
HtmlLayoutContainer descr;
|
HtmlLayoutContainer descr;
|
||||||
|
|
||||||
if (p.getDescription() == null) {
|
if (p.getDescription() == null) {
|
||||||
descr = new HtmlLayoutContainer(
|
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'></p>");
|
||||||
"<p style='margin-left:5px !important;'></p>");
|
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
// listBox.setToolTip(p.getDescription());
|
// listBox.setToolTip(p.getDescription());
|
||||||
descr = new HtmlLayoutContainer(
|
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>" + p.getDescription() + "</p>");
|
||||||
"<p style='margin-left:5px !important;'>"
|
|
||||||
+ p.getDescription() + "</p>");
|
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
}
|
}
|
||||||
horiz.add(listBox, new BoxLayoutData(new Margins()));
|
horiz.add(listBox, new BoxLayoutData(new Margins()));
|
||||||
|
@ -82,17 +80,11 @@ public class BooleanFld extends AbstractFld {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public String getValue() {
|
public String getValue() {
|
||||||
return listBox.getCurrentValue();
|
return listBox.getCurrentValue();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public Widget getWidget() {
|
public Widget getWidget() {
|
||||||
return fieldContainer;
|
return fieldContainer;
|
||||||
|
|
|
@ -31,12 +31,11 @@ import com.sencha.gxt.widget.core.client.form.ComboBox;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ColumnFld extends AbstractFld implements
|
public class ColumnFld extends AbstractFld implements TabularFldChangeEventHandler {
|
||||||
TabularFldChangeEventHandler {
|
|
||||||
|
|
||||||
private String defaultColumn;
|
private String defaultColumn;
|
||||||
private ComboBox<ColumnItem> comboBox;
|
private ComboBox<ColumnItem> comboBox;
|
||||||
|
@ -49,14 +48,14 @@ public class ColumnFld extends AbstractFld implements
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param parameter
|
* @param parameter
|
||||||
|
* parameter
|
||||||
*/
|
*/
|
||||||
public ColumnFld(Parameter parameter) {
|
public ColumnFld(Parameter parameter) {
|
||||||
super(parameter);
|
super(parameter);
|
||||||
|
|
||||||
ColumnParameter columnParameter = (ColumnParameter) parameter;
|
ColumnParameter columnParameter = (ColumnParameter) parameter;
|
||||||
|
|
||||||
referredTabularParameterName = columnParameter
|
referredTabularParameterName = columnParameter.getReferredTabularParameterName();
|
||||||
.getReferredTabularParameterName();
|
|
||||||
defaultColumn = columnParameter.getDefaultColumn();
|
defaultColumn = columnParameter.getDefaultColumn();
|
||||||
|
|
||||||
fieldContainer = new SimpleContainer();
|
fieldContainer = new SimpleContainer();
|
||||||
|
@ -64,8 +63,7 @@ public class ColumnFld extends AbstractFld implements
|
||||||
horiz.setPack(BoxLayoutPack.START);
|
horiz.setPack(BoxLayoutPack.START);
|
||||||
horiz.setEnableOverflow(false);
|
horiz.setEnableOverflow(false);
|
||||||
|
|
||||||
ColumnItemPropertiesCombo props = GWT
|
ColumnItemPropertiesCombo props = GWT.create(ColumnItemPropertiesCombo.class);
|
||||||
.create(ColumnItemPropertiesCombo.class);
|
|
||||||
|
|
||||||
store = new ListStore<ColumnItem>(props.id());
|
store = new ListStore<ColumnItem>(props.id());
|
||||||
|
|
||||||
|
@ -78,15 +76,13 @@ public class ColumnFld extends AbstractFld implements
|
||||||
HtmlLayoutContainer descr;
|
HtmlLayoutContainer descr;
|
||||||
|
|
||||||
if (columnParameter.getDescription() == null) {
|
if (columnParameter.getDescription() == null) {
|
||||||
descr = new HtmlLayoutContainer(
|
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'></p>");
|
||||||
"<p style='margin-left:5px !important;'></p>");
|
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
// comboBox.setToolTip(columnParameter.getDescription());
|
// comboBox.setToolTip(columnParameter.getDescription());
|
||||||
descr = new HtmlLayoutContainer(
|
descr = new HtmlLayoutContainer(
|
||||||
"<p style='margin-left:5px !important;'>"
|
"<p style='margin-left:5px !important;'>" + columnParameter.getDescription() + "</p>");
|
||||||
+ columnParameter.getDescription() + "</p>");
|
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -105,12 +101,10 @@ public class ColumnFld extends AbstractFld implements
|
||||||
VerticalLayoutContainer vField = new VerticalLayoutContainer();
|
VerticalLayoutContainer vField = new VerticalLayoutContainer();
|
||||||
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer(
|
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer(
|
||||||
"<div class='workflow-parameters-description'><p>Select table from parameter "
|
"<div class='workflow-parameters-description'><p>Select table from parameter "
|
||||||
+ Format.ellipse(referredTabularParameterName, 30)
|
+ Format.ellipse(referredTabularParameterName, 30) + "</p></div>");
|
||||||
+ "</p></div>");
|
|
||||||
typeDescription.setStylePrimaryName("workflow-parameters-description");
|
typeDescription.setStylePrimaryName("workflow-parameters-description");
|
||||||
vField.add(comboBox, new VerticalLayoutData(1, -1, new Margins(0)));
|
vField.add(comboBox, new VerticalLayoutData(1, -1, new Margins(0)));
|
||||||
vField.add(typeDescription, new VerticalLayoutData(-1, -1, new Margins(
|
vField.add(typeDescription, new VerticalLayoutData(-1, -1, new Margins(0)));
|
||||||
0)));
|
|
||||||
vContainer.add(vField);
|
vContainer.add(vField);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -119,18 +113,13 @@ public class ColumnFld extends AbstractFld implements
|
||||||
VerticalLayoutContainer vField = new VerticalLayoutContainer();
|
VerticalLayoutContainer vField = new VerticalLayoutContainer();
|
||||||
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer(
|
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer(
|
||||||
"<div class='workflow-parameters-description'><p>Columns of Table "
|
"<div class='workflow-parameters-description'><p>Columns of Table "
|
||||||
+ Format.ellipse(tableItem.getName(), 30)
|
+ Format.ellipse(tableItem.getName(), 30) + "</p></div>");
|
||||||
+ "</p></div>");
|
|
||||||
typeDescription.setStylePrimaryName("workflow-parameters-description");
|
typeDescription.setStylePrimaryName("workflow-parameters-description");
|
||||||
vField.add(comboBox, new VerticalLayoutData(1, -1, new Margins(0)));
|
vField.add(comboBox, new VerticalLayoutData(1, -1, new Margins(0)));
|
||||||
vField.add(typeDescription, new VerticalLayoutData(-1, -1, new Margins(
|
vField.add(typeDescription, new VerticalLayoutData(-1, -1, new Margins(0)));
|
||||||
0)));
|
|
||||||
vContainer.add(vField);
|
vContainer.add(vField);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public String getValue() {
|
public String getValue() {
|
||||||
if (tableItemSimple == null) {
|
if (tableItemSimple == null) {
|
||||||
|
@ -149,9 +138,6 @@ public class ColumnFld extends AbstractFld implements
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public Widget getWidget() {
|
public Widget getWidget() {
|
||||||
return fieldContainer;
|
return fieldContainer;
|
||||||
|
|
|
@ -39,12 +39,11 @@ import com.sencha.gxt.widget.core.client.grid.Grid;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ColumnListFld extends AbstractFld implements
|
public class ColumnListFld extends AbstractFld implements TabularFldChangeEventHandler {
|
||||||
TabularFldChangeEventHandler {
|
|
||||||
|
|
||||||
interface LabelTemplates extends XTemplates {
|
interface LabelTemplates extends XTemplates {
|
||||||
@XTemplate("<span title=\"{value}\">{value}</span>")
|
@XTemplate("<span title=\"{value}\">{value}</span>")
|
||||||
|
@ -63,6 +62,7 @@ public class ColumnListFld extends AbstractFld implements
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @param parameter
|
* @param parameter
|
||||||
|
* parameter
|
||||||
*/
|
*/
|
||||||
public ColumnListFld(Parameter parameter) {
|
public ColumnListFld(Parameter parameter) {
|
||||||
super(parameter);
|
super(parameter);
|
||||||
|
@ -80,15 +80,13 @@ public class ColumnListFld extends AbstractFld implements
|
||||||
HtmlLayoutContainer descr;
|
HtmlLayoutContainer descr;
|
||||||
|
|
||||||
if (columnListParameter.getDescription() == null) {
|
if (columnListParameter.getDescription() == null) {
|
||||||
descr = new HtmlLayoutContainer(
|
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'></p>");
|
||||||
"<p style='margin-left:5px !important;'></p>");
|
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
// grid.setToolTip(columnListParameter.getDescription());
|
// grid.setToolTip(columnListParameter.getDescription());
|
||||||
descr = new HtmlLayoutContainer(
|
descr = new HtmlLayoutContainer(
|
||||||
"<p style='margin-left:5px !important;'>"
|
"<p style='margin-left:5px !important;'>" + columnListParameter.getDescription() + "</p>");
|
||||||
+ columnListParameter.getDescription() + "</p>");
|
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -105,15 +103,13 @@ public class ColumnListFld extends AbstractFld implements
|
||||||
private void createGrid() {
|
private void createGrid() {
|
||||||
ColumnItemProperties props = GWT.create(ColumnItemProperties.class);
|
ColumnItemProperties props = GWT.create(ColumnItemProperties.class);
|
||||||
|
|
||||||
ColumnConfig<ColumnItem, String> labelCol = new ColumnConfig<ColumnItem, String>(
|
ColumnConfig<ColumnItem, String> labelCol = new ColumnConfig<ColumnItem, String>(props.label());
|
||||||
props.label());
|
|
||||||
|
|
||||||
labelCol.setCell(new AbstractCell<String>() {
|
labelCol.setCell(new AbstractCell<String>() {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void render(Context context, String value, SafeHtmlBuilder sb) {
|
public void render(Context context, String value, SafeHtmlBuilder sb) {
|
||||||
LabelTemplates labelTemplates = GWT
|
LabelTemplates labelTemplates = GWT.create(LabelTemplates.class);
|
||||||
.create(LabelTemplates.class);
|
|
||||||
sb.append(labelTemplates.format(value));
|
sb.append(labelTemplates.format(value));
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -150,13 +146,10 @@ public class ColumnListFld extends AbstractFld implements
|
||||||
VerticalLayoutContainer vField = new VerticalLayoutContainer();
|
VerticalLayoutContainer vField = new VerticalLayoutContainer();
|
||||||
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer(
|
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer(
|
||||||
"<div class='workflow-parameters-description'><p>Select table from parameter "
|
"<div class='workflow-parameters-description'><p>Select table from parameter "
|
||||||
+ Format.ellipse(columnListParameter
|
+ Format.ellipse(columnListParameter.getReferredTabularParameterName(), 30) + "</p></div>");
|
||||||
.getReferredTabularParameterName(), 30)
|
|
||||||
+ "</p></div>");
|
|
||||||
typeDescription.setStylePrimaryName("workflow-parameters-description");
|
typeDescription.setStylePrimaryName("workflow-parameters-description");
|
||||||
vField.add(grid, new VerticalLayoutData(-1, -1, new Margins(0)));
|
vField.add(grid, new VerticalLayoutData(-1, -1, new Margins(0)));
|
||||||
vField.add(typeDescription, new VerticalLayoutData(-1, -1, new Margins(
|
vField.add(typeDescription, new VerticalLayoutData(-1, -1, new Margins(0)));
|
||||||
0)));
|
|
||||||
vContainer.add(vField);
|
vContainer.add(vField);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -165,18 +158,13 @@ public class ColumnListFld extends AbstractFld implements
|
||||||
VerticalLayoutContainer vField = new VerticalLayoutContainer();
|
VerticalLayoutContainer vField = new VerticalLayoutContainer();
|
||||||
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer(
|
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer(
|
||||||
"<div class='workflow-parameters-description'><p>Columns of Table "
|
"<div class='workflow-parameters-description'><p>Columns of Table "
|
||||||
+ Format.ellipse(tableItem.getName(), 30)
|
+ Format.ellipse(tableItem.getName(), 30) + "</p></div>");
|
||||||
+ "</p></div>");
|
|
||||||
typeDescription.setStylePrimaryName("workflow-parameters-description");
|
typeDescription.setStylePrimaryName("workflow-parameters-description");
|
||||||
vField.add(grid, new VerticalLayoutData(-1, -1, new Margins(0)));
|
vField.add(grid, new VerticalLayoutData(-1, -1, new Margins(0)));
|
||||||
vField.add(typeDescription, new VerticalLayoutData(-1, -1, new Margins(
|
vField.add(typeDescription, new VerticalLayoutData(-1, -1, new Margins(0)));
|
||||||
0)));
|
|
||||||
vContainer.add(vField);
|
vContainer.add(vField);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public String getValue() {
|
public String getValue() {
|
||||||
String separator = columnListParameter.getSeparator();
|
String separator = columnListParameter.getSeparator();
|
||||||
|
@ -201,17 +189,11 @@ public class ColumnListFld extends AbstractFld implements
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public Widget getWidget() {
|
public Widget getWidget() {
|
||||||
return fieldContainer;
|
return fieldContainer;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public boolean isValid() {
|
public boolean isValid() {
|
||||||
return (sm.getSelection() != null && sm.getSelection().size() > 0);
|
return (sm.getSelection() != null && sm.getSelection().size() > 0);
|
||||||
|
|
|
@ -23,8 +23,8 @@ import com.sencha.gxt.widget.core.client.form.DateField;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class DateFld extends AbstractFld {
|
public class DateFld extends AbstractFld {
|
||||||
|
@ -35,6 +35,7 @@ public class DateFld extends AbstractFld {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param parameter
|
* @param parameter
|
||||||
|
* parameter
|
||||||
*/
|
*/
|
||||||
public DateFld(Parameter parameter) {
|
public DateFld(Parameter parameter) {
|
||||||
super(parameter);
|
super(parameter);
|
||||||
|
@ -57,26 +58,21 @@ public class DateFld extends AbstractFld {
|
||||||
HtmlLayoutContainer descr;
|
HtmlLayoutContainer descr;
|
||||||
|
|
||||||
if (p.getDescription() == null) {
|
if (p.getDescription() == null) {
|
||||||
descr = new HtmlLayoutContainer(
|
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'></p>");
|
||||||
"<p style='margin-left:5px !important;'></p>");
|
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
// textField.setToolTip(p.getDescription());
|
// textField.setToolTip(p.getDescription());
|
||||||
descr = new HtmlLayoutContainer(
|
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>" + p.getDescription() + "</p>");
|
||||||
"<p style='margin-left:5px !important;'>"
|
|
||||||
+ p.getDescription() + "</p>");
|
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
}
|
}
|
||||||
|
|
||||||
SimpleContainer vContainer = new SimpleContainer();
|
SimpleContainer vContainer = new SimpleContainer();
|
||||||
VerticalLayoutContainer vField = new VerticalLayoutContainer();
|
VerticalLayoutContainer vField = new VerticalLayoutContainer();
|
||||||
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer(
|
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer("Date Value");
|
||||||
"Date Value");
|
|
||||||
typeDescription.setStylePrimaryName("workflow-parameters-description");
|
typeDescription.setStylePrimaryName("workflow-parameters-description");
|
||||||
vField.add(dateField, new VerticalLayoutData(-1, -1, new Margins(0)));
|
vField.add(dateField, new VerticalLayoutData(-1, -1, new Margins(0)));
|
||||||
vField.add(typeDescription, new VerticalLayoutData(-1, -1, new Margins(
|
vField.add(typeDescription, new VerticalLayoutData(-1, -1, new Margins(0)));
|
||||||
0)));
|
|
||||||
vContainer.add(vField);
|
vContainer.add(vField);
|
||||||
|
|
||||||
fieldContainer = new SimpleContainer();
|
fieldContainer = new SimpleContainer();
|
||||||
|
@ -92,18 +88,12 @@ public class DateFld extends AbstractFld {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public String getValue() {
|
public String getValue() {
|
||||||
String dateS = dateFormat.format(dateField.getCurrentValue());
|
String dateS = dateFormat.format(dateField.getCurrentValue());
|
||||||
return dateS;
|
return dateS;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public Widget getWidget() {
|
public Widget getWidget() {
|
||||||
return fieldContainer;
|
return fieldContainer;
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
package org.gcube.portlets.widgets.dataminermanagerwidget.client.parametersfield;
|
package org.gcube.portlets.widgets.dataminermanagerwidget.client.parametersfield;
|
||||||
|
|
||||||
|
|
||||||
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ObjectParameter;
|
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ObjectParameter;
|
||||||
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
|
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
|
||||||
|
|
||||||
|
@ -17,21 +16,23 @@ import com.sencha.gxt.widget.core.client.form.DoubleField;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class DoubleFld extends AbstractFld {
|
public class DoubleFld extends AbstractFld {
|
||||||
|
|
||||||
private SimpleContainer fieldContainer;
|
private SimpleContainer fieldContainer;
|
||||||
private DoubleField numberField;
|
private DoubleField numberField;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param operator
|
*
|
||||||
|
* @param parameter
|
||||||
|
* parameter
|
||||||
*/
|
*/
|
||||||
public DoubleFld(Parameter parameter) {
|
public DoubleFld(Parameter parameter) {
|
||||||
super(parameter);
|
super(parameter);
|
||||||
fieldContainer=new SimpleContainer();
|
fieldContainer = new SimpleContainer();
|
||||||
HBoxLayoutContainer horiz = new HBoxLayoutContainer();
|
HBoxLayoutContainer horiz = new HBoxLayoutContainer();
|
||||||
horiz.setPack(BoxLayoutPack.START);
|
horiz.setPack(BoxLayoutPack.START);
|
||||||
horiz.setEnableOverflow(false);
|
horiz.setEnableOverflow(false);
|
||||||
|
@ -43,7 +44,7 @@ public class DoubleFld extends AbstractFld {
|
||||||
if (p.getDefaultValue() != null)
|
if (p.getDefaultValue() != null)
|
||||||
numberField.setValue(Double.parseDouble(p.getDefaultValue()));
|
numberField.setValue(Double.parseDouble(p.getDefaultValue()));
|
||||||
numberField.setAllowBlank(false);
|
numberField.setAllowBlank(false);
|
||||||
|
|
||||||
HtmlLayoutContainer descr;
|
HtmlLayoutContainer descr;
|
||||||
|
|
||||||
if (p.getDescription() == null) {
|
if (p.getDescription() == null) {
|
||||||
|
@ -51,52 +52,40 @@ public class DoubleFld extends AbstractFld {
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
//numberField.setToolTip(p.getDescription());
|
// numberField.setToolTip(p.getDescription());
|
||||||
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>"
|
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>" + p.getDescription() + "</p>");
|
||||||
+ p.getDescription() + "</p>");
|
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
}
|
}
|
||||||
|
|
||||||
SimpleContainer vContainer=new SimpleContainer();
|
SimpleContainer vContainer = new SimpleContainer();
|
||||||
VerticalLayoutContainer vField = new VerticalLayoutContainer();
|
VerticalLayoutContainer vField = new VerticalLayoutContainer();
|
||||||
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer(
|
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer("Double Value");
|
||||||
"Double Value");
|
|
||||||
typeDescription.setStylePrimaryName("workflow-parameters-description");
|
typeDescription.setStylePrimaryName("workflow-parameters-description");
|
||||||
vField.add(numberField, new VerticalLayoutData(-1,-1,new Margins(0)));
|
vField.add(numberField, new VerticalLayoutData(-1, -1, new Margins(0)));
|
||||||
vField.add(typeDescription, new VerticalLayoutData(-1,-1,new Margins(0)));
|
vField.add(typeDescription, new VerticalLayoutData(-1, -1, new Margins(0)));
|
||||||
vContainer.add(vField);
|
vContainer.add(vField);
|
||||||
|
|
||||||
horiz.add(vContainer, new BoxLayoutData(new Margins()));
|
horiz.add(vContainer, new BoxLayoutData(new Margins()));
|
||||||
horiz.add(descr, new BoxLayoutData(new Margins()));
|
horiz.add(descr, new BoxLayoutData(new Margins()));
|
||||||
|
|
||||||
fieldContainer.add(horiz);
|
fieldContainer.add(horiz);
|
||||||
|
|
||||||
fieldContainer.forceLayout();
|
fieldContainer.forceLayout();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public String getValue() {
|
public String getValue() {
|
||||||
return numberField.getCurrentValue().toString();
|
return numberField.getCurrentValue().toString();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public Widget getWidget() {
|
public Widget getWidget() {
|
||||||
return fieldContainer;
|
return fieldContainer;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public boolean isValid() {
|
public boolean isValid() {
|
||||||
return numberField.isValid();
|
return numberField.isValid();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,7 +3,6 @@
|
||||||
*/
|
*/
|
||||||
package org.gcube.portlets.widgets.dataminermanagerwidget.client.parametersfield;
|
package org.gcube.portlets.widgets.dataminermanagerwidget.client.parametersfield;
|
||||||
|
|
||||||
|
|
||||||
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.EnumParameter;
|
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.EnumParameter;
|
||||||
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
|
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
|
||||||
|
|
||||||
|
@ -20,8 +19,8 @@ import com.sencha.gxt.widget.core.client.form.SimpleComboBox;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class EnumFld extends AbstractFld {
|
public class EnumFld extends AbstractFld {
|
||||||
|
@ -31,6 +30,7 @@ public class EnumFld extends AbstractFld {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param parameter
|
* @param parameter
|
||||||
|
* parameter
|
||||||
*/
|
*/
|
||||||
public EnumFld(Parameter parameter) {
|
public EnumFld(Parameter parameter) {
|
||||||
super(parameter);
|
super(parameter);
|
||||||
|
@ -58,9 +58,8 @@ public class EnumFld extends AbstractFld {
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
//listBox.setToolTip(p.getDescription());
|
// listBox.setToolTip(p.getDescription());
|
||||||
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>"
|
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>" + p.getDescription() + "</p>");
|
||||||
+ p.getDescription() + "</p>");
|
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
}
|
}
|
||||||
horiz.add(listBox, new BoxLayoutData(new Margins()));
|
horiz.add(listBox, new BoxLayoutData(new Margins()));
|
||||||
|
@ -71,17 +70,11 @@ public class EnumFld extends AbstractFld {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public String getValue() {
|
public String getValue() {
|
||||||
return listBox.getCurrentValue();
|
return listBox.getCurrentValue();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public Widget getWidget() {
|
public Widget getWidget() {
|
||||||
return fieldContainer;
|
return fieldContainer;
|
||||||
|
@ -91,5 +84,5 @@ public class EnumFld extends AbstractFld {
|
||||||
public boolean isValid() {
|
public boolean isValid() {
|
||||||
return listBox.isValid();
|
return listBox.isValid();
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -43,8 +43,8 @@ import com.sencha.gxt.widget.core.client.form.TextField;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class FileFld extends AbstractFld {
|
public class FileFld extends AbstractFld {
|
||||||
|
@ -52,7 +52,7 @@ public class FileFld extends AbstractFld {
|
||||||
private VerticalLayoutContainer vp;
|
private VerticalLayoutContainer vp;
|
||||||
private SimpleContainer fieldContainer;
|
private SimpleContainer fieldContainer;
|
||||||
private HBoxLayoutContainer horiz;
|
private HBoxLayoutContainer horiz;
|
||||||
|
|
||||||
// FileSelector fileSelector;
|
// FileSelector fileSelector;
|
||||||
private WorkspaceExplorerSelectDialog wselectDialog;
|
private WorkspaceExplorerSelectDialog wselectDialog;
|
||||||
private TextButton selectButton;
|
private TextButton selectButton;
|
||||||
|
@ -67,10 +67,9 @@ public class FileFld extends AbstractFld {
|
||||||
private FileParameter fileParameter;
|
private FileParameter fileParameter;
|
||||||
private boolean created = false;
|
private boolean created = false;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param parameter
|
* @param parameter
|
||||||
|
* parameter
|
||||||
*/
|
*/
|
||||||
public FileFld(Parameter parameter) {
|
public FileFld(Parameter parameter) {
|
||||||
super(parameter);
|
super(parameter);
|
||||||
|
@ -84,7 +83,7 @@ public class FileFld extends AbstractFld {
|
||||||
retrieveTabularResourceInfo();
|
retrieveTabularResourceInfo();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void bind() {
|
private void bind() {
|
||||||
EventBusProvider.INSTANCE.addHandler(TabularResourceInfoEvent.TYPE,
|
EventBusProvider.INSTANCE.addHandler(TabularResourceInfoEvent.TYPE,
|
||||||
new TabularResourceInfoEvent.TabularResourceInfoEventHandler() {
|
new TabularResourceInfoEvent.TabularResourceInfoEventHandler() {
|
||||||
|
@ -107,8 +106,8 @@ public class FileFld extends AbstractFld {
|
||||||
TabularResourceInfoRequestEvent event = new TabularResourceInfoRequestEvent();
|
TabularResourceInfoRequestEvent event = new TabularResourceInfoRequestEvent();
|
||||||
EventBusProvider.INSTANCE.fireEvent(event);
|
EventBusProvider.INSTANCE.fireEvent(event);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void create(){
|
private void create() {
|
||||||
SimpleContainer tabContainer = new SimpleContainer();
|
SimpleContainer tabContainer = new SimpleContainer();
|
||||||
vp = new VerticalLayoutContainer();
|
vp = new VerticalLayoutContainer();
|
||||||
init();
|
init();
|
||||||
|
@ -126,8 +125,8 @@ public class FileFld extends AbstractFld {
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>"
|
descr = new HtmlLayoutContainer(
|
||||||
+ fileParameter.getDescription() + "</p>");
|
"<p style='margin-left:5px !important;'>" + fileParameter.getDescription() + "</p>");
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -165,8 +164,7 @@ public class FileFld extends AbstractFld {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onFailed(Throwable throwable) {
|
public void onFailed(Throwable throwable) {
|
||||||
Log.error("Error in create project: "
|
Log.error("Error in create project: " + throwable.getLocalizedMessage());
|
||||||
+ throwable.getLocalizedMessage());
|
|
||||||
UtilsGXT3.alert("Error", throwable.getLocalizedMessage());
|
UtilsGXT3.alert("Error", throwable.getLocalizedMessage());
|
||||||
throwable.printStackTrace();
|
throwable.printStackTrace();
|
||||||
}
|
}
|
||||||
|
@ -185,7 +183,6 @@ public class FileFld extends AbstractFld {
|
||||||
wselectDialog.addWorkspaceExplorerSelectNotificationListener(handler);
|
wselectDialog.addWorkspaceExplorerSelectNotificationListener(handler);
|
||||||
wselectDialog.setZIndex(XDOM.getTopZIndex());
|
wselectDialog.setZIndex(XDOM.getTopZIndex());
|
||||||
|
|
||||||
|
|
||||||
selectTRButton = new TextButton("Use Tabular Resource");
|
selectTRButton = new TextButton("Use Tabular Resource");
|
||||||
selectTRButton.addSelectHandler(new SelectEvent.SelectHandler() {
|
selectTRButton.addSelectHandler(new SelectEvent.SelectHandler() {
|
||||||
|
|
||||||
|
@ -194,8 +191,7 @@ public class FileFld extends AbstractFld {
|
||||||
useTabularResource();
|
useTabularResource();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
selectTRButton.setIcon(DataMinerManagerPanel.resources
|
selectTRButton.setIcon(DataMinerManagerPanel.resources.tabularResource());
|
||||||
.tabularResource());
|
|
||||||
selectTRButton.setToolTip("Use Tabular Resource");
|
selectTRButton.setToolTip("Use Tabular Resource");
|
||||||
|
|
||||||
selectTRButton2 = new TextButton("");
|
selectTRButton2 = new TextButton("");
|
||||||
|
@ -207,12 +203,9 @@ public class FileFld extends AbstractFld {
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
selectTRButton2.setIcon(DataMinerManagerPanel.resources
|
selectTRButton2.setIcon(DataMinerManagerPanel.resources.tabularResource());
|
||||||
.tabularResource());
|
|
||||||
selectTRButton2.setToolTip("Use Tabular Resource");
|
selectTRButton2.setToolTip("Use Tabular Resource");
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
selectButton = new TextButton("Select File");
|
selectButton = new TextButton("Select File");
|
||||||
selectButton.setIcon(DataMinerManagerPanel.resources.folderExplore());
|
selectButton.setIcon(DataMinerManagerPanel.resources.folderExplore());
|
||||||
selectButton.addSelectHandler(new SelectEvent.SelectHandler() {
|
selectButton.addSelectHandler(new SelectEvent.SelectHandler() {
|
||||||
|
@ -260,82 +253,69 @@ public class FileFld extends AbstractFld {
|
||||||
downloadButton.setToolTip("Download File");
|
downloadButton.setToolTip("Download File");
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void useTabularResource() {
|
private void useTabularResource() {
|
||||||
Log.debug("TabularResourceData: " + tabularResourceData);
|
Log.debug("TabularResourceData: " + tabularResourceData);
|
||||||
selectedFileItem = new ItemDescription(
|
selectedFileItem = new ItemDescription(tabularResourceData.getTabularResourceId(),
|
||||||
tabularResourceData.getTabularResourceId(),
|
tabularResourceData.getName(), "", "", tabularResourceData.getType());
|
||||||
tabularResourceData.getName(),
|
selectedFileItem.setPublicLink(tabularResourceData.getTabularResourceId());
|
||||||
"","",
|
|
||||||
tabularResourceData.getType());
|
|
||||||
selectedFileItem.setPublicLink(tabularResourceData.getTabularResourceId());
|
|
||||||
showFieldWithTRSelection();
|
showFieldWithTRSelection();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
private void retrieveFileInformation(final Item item) {
|
private void retrieveFileInformation(final Item item) {
|
||||||
Log.debug("Retrieved: " + item);
|
Log.debug("Retrieved: " + item);
|
||||||
final ItemDescription itemDescription = new ItemDescription(
|
final ItemDescription itemDescription = new ItemDescription(item.getId(), item.getName(), item.getOwner(),
|
||||||
item.getId(), item.getName(), item.getOwner(), item.getPath(),
|
item.getPath(), item.getType().name());
|
||||||
item.getType().name());
|
|
||||||
|
|
||||||
DataMinerPortletServiceAsync.INSTANCE.getPublicLink(itemDescription,
|
DataMinerPortletServiceAsync.INSTANCE.getPublicLink(itemDescription, new AsyncCallback<String>() {
|
||||||
new AsyncCallback<String>() {
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onFailure(Throwable caught) {
|
public void onFailure(Throwable caught) {
|
||||||
Log.error("Error in retrieveFileInformation: "
|
Log.error("Error in retrieveFileInformation: " + caught.getMessage());
|
||||||
+ caught.getMessage());
|
if (caught instanceof SessionExpiredServiceException) {
|
||||||
if (caught instanceof SessionExpiredServiceException) {
|
UtilsGXT3.alert("Error", "Expired Session");
|
||||||
UtilsGXT3.alert("Error", "Expired Session");
|
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
UtilsGXT3.alert("Error",
|
UtilsGXT3.alert("Error", "Error retrieving file informations: " + caught.getLocalizedMessage());
|
||||||
"Error retrieving file informations: "
|
}
|
||||||
+ caught.getLocalizedMessage());
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onSuccess(String result) {
|
public void onSuccess(String result) {
|
||||||
itemDescription.setPublicLink(result);
|
itemDescription.setPublicLink(result);
|
||||||
selectedFileItem = itemDescription;
|
selectedFileItem = itemDescription;
|
||||||
Log.debug("SelectedFileItem: " + selectedFileItem);
|
Log.debug("SelectedFileItem: " + selectedFileItem);
|
||||||
showFieldWithFileSelection();
|
showFieldWithFileSelection();
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void downloadFile() {
|
private void downloadFile() {
|
||||||
if (selectedFileItem != null) {
|
if (selectedFileItem != null) {
|
||||||
DataMinerPortletServiceAsync.INSTANCE.getPublicLink(
|
DataMinerPortletServiceAsync.INSTANCE.getPublicLink(selectedFileItem, new AsyncCallback<String>() {
|
||||||
selectedFileItem, new AsyncCallback<String>() {
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onFailure(Throwable caught) {
|
public void onFailure(Throwable caught) {
|
||||||
if (caught instanceof SessionExpiredServiceException) {
|
if (caught instanceof SessionExpiredServiceException) {
|
||||||
EventBusProvider.INSTANCE
|
EventBusProvider.INSTANCE.fireEvent(new SessionExpiredEvent());
|
||||||
.fireEvent(new SessionExpiredEvent());
|
} else {
|
||||||
} else {
|
Log.error("Error downloading file: " + caught.getLocalizedMessage());
|
||||||
Log.error("Error downloading file: "
|
UtilsGXT3.alert("Error", caught.getLocalizedMessage());
|
||||||
+ caught.getLocalizedMessage());
|
}
|
||||||
UtilsGXT3.alert("Error",
|
caught.printStackTrace();
|
||||||
caught.getLocalizedMessage());
|
|
||||||
}
|
|
||||||
caught.printStackTrace();
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onSuccess(String link) {
|
public void onSuccess(String link) {
|
||||||
Log.debug("Retrieved link: " + link);
|
Log.debug("Retrieved link: " + link);
|
||||||
Window.open(link, selectedFileItem.getName(), "");
|
Window.open(link, selectedFileItem.getName(), "");
|
||||||
}
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
UtilsGXT3.info("Attention", "Select a file!");
|
UtilsGXT3.info("Attention", "Select a file!");
|
||||||
|
@ -343,7 +323,6 @@ public class FileFld extends AbstractFld {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
private void showNoSelectionField() {
|
private void showNoSelectionField() {
|
||||||
vp.clear();
|
vp.clear();
|
||||||
vp.add(selectTRButton);
|
vp.add(selectTRButton);
|
||||||
|
@ -351,8 +330,7 @@ public class FileFld extends AbstractFld {
|
||||||
vp.forceLayout();
|
vp.forceLayout();
|
||||||
fieldContainer.forceLayout();
|
fieldContainer.forceLayout();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
private void showFieldWithFileSelection() {
|
private void showFieldWithFileSelection() {
|
||||||
String fileName = selectedFileItem.getName();
|
String fileName = selectedFileItem.getName();
|
||||||
|
|
||||||
|
@ -376,7 +354,7 @@ public class FileFld extends AbstractFld {
|
||||||
fieldContainer.forceLayout();
|
fieldContainer.forceLayout();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void showFieldWithTRSelection() {
|
private void showFieldWithTRSelection() {
|
||||||
String fileName = selectedFileItem.getName();
|
String fileName = selectedFileItem.getName();
|
||||||
|
|
||||||
|
@ -401,10 +379,6 @@ public class FileFld extends AbstractFld {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public boolean isValid() {
|
public boolean isValid() {
|
||||||
return (selectedFileItem != null);
|
return (selectedFileItem != null);
|
||||||
|
@ -417,8 +391,7 @@ public class FileFld extends AbstractFld {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String getValue() {
|
public String getValue() {
|
||||||
return (selectedFileItem == null) ? null : selectedFileItem
|
return (selectedFileItem == null) ? null : selectedFileItem.getPublicLink();
|
||||||
.getPublicLink();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
package org.gcube.portlets.widgets.dataminermanagerwidget.client.parametersfield;
|
package org.gcube.portlets.widgets.dataminermanagerwidget.client.parametersfield;
|
||||||
|
|
||||||
|
|
||||||
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ObjectParameter;
|
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ObjectParameter;
|
||||||
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
|
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
|
||||||
|
|
||||||
|
@ -17,8 +16,8 @@ import com.sencha.gxt.widget.core.client.form.FloatField;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class FloatFld extends AbstractFld {
|
public class FloatFld extends AbstractFld {
|
||||||
|
@ -27,7 +26,9 @@ public class FloatFld extends AbstractFld {
|
||||||
private FloatField numberField;
|
private FloatField numberField;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param operator
|
*
|
||||||
|
* @param parameter
|
||||||
|
* parameter
|
||||||
*/
|
*/
|
||||||
public FloatFld(Parameter parameter) {
|
public FloatFld(Parameter parameter) {
|
||||||
super(parameter);
|
super(parameter);
|
||||||
|
@ -51,20 +52,17 @@ public class FloatFld extends AbstractFld {
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
//numberField.setToolTip(p.getDescription());
|
// numberField.setToolTip(p.getDescription());
|
||||||
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>"
|
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>" + p.getDescription() + "</p>");
|
||||||
+ p.getDescription() + "</p>");
|
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
}
|
}
|
||||||
|
|
||||||
SimpleContainer vContainer = new SimpleContainer();
|
SimpleContainer vContainer = new SimpleContainer();
|
||||||
VerticalLayoutContainer vField = new VerticalLayoutContainer();
|
VerticalLayoutContainer vField = new VerticalLayoutContainer();
|
||||||
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer(
|
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer("Float Value");
|
||||||
"Float Value");
|
|
||||||
typeDescription.setStylePrimaryName("workflow-parameters-description");
|
typeDescription.setStylePrimaryName("workflow-parameters-description");
|
||||||
vField.add(numberField, new VerticalLayoutData(-1, -1, new Margins(0)));
|
vField.add(numberField, new VerticalLayoutData(-1, -1, new Margins(0)));
|
||||||
vField.add(typeDescription, new VerticalLayoutData(-1, -1, new Margins(
|
vField.add(typeDescription, new VerticalLayoutData(-1, -1, new Margins(0)));
|
||||||
0)));
|
|
||||||
vContainer.add(vField);
|
vContainer.add(vField);
|
||||||
|
|
||||||
horiz.add(vContainer, new BoxLayoutData(new Margins()));
|
horiz.add(vContainer, new BoxLayoutData(new Margins()));
|
||||||
|
@ -75,18 +73,12 @@ public class FloatFld extends AbstractFld {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public String getValue() {
|
public String getValue() {
|
||||||
Float f = numberField.getCurrentValue();
|
Float f = numberField.getCurrentValue();
|
||||||
return f.toString();
|
return f.toString();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public Widget getWidget() {
|
public Widget getWidget() {
|
||||||
return fieldContainer;
|
return fieldContainer;
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
package org.gcube.portlets.widgets.dataminermanagerwidget.client.parametersfield;
|
package org.gcube.portlets.widgets.dataminermanagerwidget.client.parametersfield;
|
||||||
|
|
||||||
|
|
||||||
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ObjectParameter;
|
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ObjectParameter;
|
||||||
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
|
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
|
||||||
|
|
||||||
|
@ -17,8 +16,8 @@ import com.sencha.gxt.widget.core.client.form.IntegerField;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class IntFld extends AbstractFld {
|
public class IntFld extends AbstractFld {
|
||||||
|
@ -27,7 +26,9 @@ public class IntFld extends AbstractFld {
|
||||||
private IntegerField numberField;
|
private IntegerField numberField;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param operator
|
*
|
||||||
|
* @param parameter
|
||||||
|
* parameter
|
||||||
*/
|
*/
|
||||||
public IntFld(Parameter parameter) {
|
public IntFld(Parameter parameter) {
|
||||||
super(parameter);
|
super(parameter);
|
||||||
|
@ -51,21 +52,19 @@ public class IntFld extends AbstractFld {
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
//numberField.setToolTip(p.getDescription());
|
// numberField.setToolTip(p.getDescription());
|
||||||
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>"
|
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>" + p.getDescription() + "</p>");
|
||||||
+ p.getDescription() + "</p>");
|
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
}
|
}
|
||||||
|
|
||||||
SimpleContainer vContainer=new SimpleContainer();
|
SimpleContainer vContainer = new SimpleContainer();
|
||||||
VerticalLayoutContainer vField = new VerticalLayoutContainer();
|
VerticalLayoutContainer vField = new VerticalLayoutContainer();
|
||||||
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer(
|
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer("Integer Value");
|
||||||
"Integer Value");
|
|
||||||
typeDescription.setStylePrimaryName("workflow-parameters-description");
|
typeDescription.setStylePrimaryName("workflow-parameters-description");
|
||||||
vField.add(numberField, new VerticalLayoutData(-1,-1,new Margins(0)));
|
vField.add(numberField, new VerticalLayoutData(-1, -1, new Margins(0)));
|
||||||
vField.add(typeDescription, new VerticalLayoutData(-1,-1,new Margins(0)));
|
vField.add(typeDescription, new VerticalLayoutData(-1, -1, new Margins(0)));
|
||||||
vContainer.add(vField);
|
vContainer.add(vField);
|
||||||
|
|
||||||
horiz.add(vContainer, new BoxLayoutData(new Margins()));
|
horiz.add(vContainer, new BoxLayoutData(new Margins()));
|
||||||
horiz.add(descr, new BoxLayoutData(new Margins()));
|
horiz.add(descr, new BoxLayoutData(new Margins()));
|
||||||
|
|
||||||
|
@ -74,24 +73,17 @@ public class IntFld extends AbstractFld {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public String getValue() {
|
public String getValue() {
|
||||||
Integer i = numberField.getCurrentValue();
|
Integer i = numberField.getCurrentValue();
|
||||||
return i.toString();
|
return i.toString();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public Widget getWidget() {
|
public Widget getWidget() {
|
||||||
return fieldContainer;
|
return fieldContainer;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean isValid() {
|
public boolean isValid() {
|
||||||
return numberField.isValid();
|
return numberField.isValid();
|
||||||
|
|
|
@ -28,7 +28,7 @@ import com.sencha.gxt.widget.core.client.form.IntegerField;
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi
|
* @author Giancarlo Panichi
|
||||||
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ListIntFld extends AbstractFld {
|
public class ListIntFld extends AbstractFld {
|
||||||
|
@ -42,23 +42,25 @@ public class ListIntFld extends AbstractFld {
|
||||||
private HBoxLayoutContainer horiz;
|
private HBoxLayoutContainer horiz;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
*
|
||||||
* @param parameter
|
* @param parameter
|
||||||
|
* parameter
|
||||||
*/
|
*/
|
||||||
public ListIntFld(Parameter parameter) {
|
public ListIntFld(Parameter parameter) {
|
||||||
super(parameter);
|
super(parameter);
|
||||||
this.listParameter = (ListParameter) parameter;
|
this.listParameter = (ListParameter) parameter;
|
||||||
|
|
||||||
listContainer = new SimpleContainer();
|
listContainer = new SimpleContainer();
|
||||||
vp = new VerticalLayoutContainer();
|
vp = new VerticalLayoutContainer();
|
||||||
items = new ArrayList<Item>();
|
items = new ArrayList<Item>();
|
||||||
addField(null);
|
addField(null);
|
||||||
listContainer.add(vp, new MarginData(new Margins()));
|
listContainer.add(vp, new MarginData(new Margins()));
|
||||||
|
|
||||||
fieldContainer = new SimpleContainer();
|
fieldContainer = new SimpleContainer();
|
||||||
horiz = new HBoxLayoutContainer();
|
horiz = new HBoxLayoutContainer();
|
||||||
horiz.setPack(BoxLayoutPack.START);
|
horiz.setPack(BoxLayoutPack.START);
|
||||||
horiz.setEnableOverflow(false);
|
horiz.setEnableOverflow(false);
|
||||||
|
|
||||||
HtmlLayoutContainer descr;
|
HtmlLayoutContainer descr;
|
||||||
|
|
||||||
if (listParameter.getDescription() == null) {
|
if (listParameter.getDescription() == null) {
|
||||||
|
@ -66,9 +68,9 @@ public class ListIntFld extends AbstractFld {
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
//listContainer.setToolTip(listParameter.getDescription());
|
// listContainer.setToolTip(listParameter.getDescription());
|
||||||
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>"
|
descr = new HtmlLayoutContainer(
|
||||||
+ listParameter.getDescription() + "</p>");
|
"<p style='margin-left:5px !important;'>" + listParameter.getDescription() + "</p>");
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -77,14 +79,13 @@ public class ListIntFld extends AbstractFld {
|
||||||
|
|
||||||
fieldContainer.add(horiz);
|
fieldContainer.add(horiz);
|
||||||
fieldContainer.forceLayout();
|
fieldContainer.forceLayout();
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void addField(Item upperItem) {
|
private void addField(Item upperItem) {
|
||||||
|
|
||||||
ObjectParameter objPar = new ObjectParameter(listParameter.getName(),
|
ObjectParameter objPar = new ObjectParameter(listParameter.getName(), listParameter.getDescription(),
|
||||||
listParameter.getDescription(), listParameter.getType(), null);
|
listParameter.getType(), null);
|
||||||
|
|
||||||
if (upperItem == null) {
|
if (upperItem == null) {
|
||||||
Item item = new Item(objPar, true);
|
Item item = new Item(objPar, true);
|
||||||
|
@ -107,25 +108,19 @@ public class ListIntFld extends AbstractFld {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param item
|
|
||||||
*/
|
|
||||||
private void removeField(Item item) {
|
private void removeField(Item item) {
|
||||||
items.remove(item);
|
items.remove(item);
|
||||||
|
|
||||||
vp.remove(item);
|
vp.remove(item);
|
||||||
|
|
||||||
if (items.size() == 1) {
|
if (items.size() == 1) {
|
||||||
items.get(0).hideCancelButton();
|
items.get(0).hideCancelButton();
|
||||||
}
|
}
|
||||||
|
|
||||||
simpleContainer.forceLayout();
|
simpleContainer.forceLayout();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public String getValue() {
|
public String getValue() {
|
||||||
String separator = listParameter.getSeparator();
|
String separator = listParameter.getSeparator();
|
||||||
|
@ -141,17 +136,11 @@ public class ListIntFld extends AbstractFld {
|
||||||
return value;
|
return value;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public Widget getWidget() {
|
public Widget getWidget() {
|
||||||
return fieldContainer;
|
return fieldContainer;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public boolean isValid() {
|
public boolean isValid() {
|
||||||
for (Item item : items)
|
for (Item item : items)
|
||||||
|
@ -167,15 +156,12 @@ public class ListIntFld extends AbstractFld {
|
||||||
private TextButton addBtn;
|
private TextButton addBtn;
|
||||||
private TextButton removeBtn;
|
private TextButton removeBtn;
|
||||||
|
|
||||||
/**
|
|
||||||
* @param objPar
|
|
||||||
*/
|
|
||||||
public Item(ObjectParameter objectParameter, boolean first) {
|
public Item(ObjectParameter objectParameter, boolean first) {
|
||||||
super();
|
super();
|
||||||
|
|
||||||
field = new IntegerField();
|
field = new IntegerField();
|
||||||
field.setAllowBlank(false);
|
field.setAllowBlank(false);
|
||||||
|
|
||||||
addBtn = new TextButton("");
|
addBtn = new TextButton("");
|
||||||
|
|
||||||
addBtn.setIcon(DataMinerManagerPanel.resources.add());
|
addBtn.setIcon(DataMinerManagerPanel.resources.add());
|
||||||
|
|
|
@ -22,8 +22,8 @@ import com.sencha.gxt.widget.core.client.container.VerticalLayoutContainer;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class ListStringFld extends AbstractFld {
|
public class ListStringFld extends AbstractFld {
|
||||||
|
@ -38,6 +38,7 @@ public class ListStringFld extends AbstractFld {
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @param parameter
|
* @param parameter
|
||||||
|
* parameter
|
||||||
*/
|
*/
|
||||||
public ListStringFld(Parameter parameter) {
|
public ListStringFld(Parameter parameter) {
|
||||||
super(parameter);
|
super(parameter);
|
||||||
|
@ -61,9 +62,9 @@ public class ListStringFld extends AbstractFld {
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
/*listContainer.setToolTip(listParameter.getDescription());*/
|
/* listContainer.setToolTip(listParameter.getDescription()); */
|
||||||
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>"
|
descr = new HtmlLayoutContainer(
|
||||||
+ listParameter.getDescription() + "</p>");
|
"<p style='margin-left:5px !important;'>" + listParameter.getDescription() + "</p>");
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -76,8 +77,8 @@ public class ListStringFld extends AbstractFld {
|
||||||
|
|
||||||
protected void addField(StringItem upperItem) {
|
protected void addField(StringItem upperItem) {
|
||||||
|
|
||||||
ObjectParameter objPar = new ObjectParameter(listParameter.getName(),
|
ObjectParameter objPar = new ObjectParameter(listParameter.getName(), listParameter.getDescription(),
|
||||||
listParameter.getDescription(), listParameter.getType(), null);
|
listParameter.getType(), null);
|
||||||
|
|
||||||
if (upperItem == null) {
|
if (upperItem == null) {
|
||||||
StringItem item = new StringItem(this, objPar, true);
|
StringItem item = new StringItem(this, objPar, true);
|
||||||
|
@ -91,30 +92,27 @@ public class ListStringFld extends AbstractFld {
|
||||||
upperItem.forceLayout();
|
upperItem.forceLayout();
|
||||||
StringItem item = new StringItem(this, objPar, false);
|
StringItem item = new StringItem(this, objPar, false);
|
||||||
items.add(pos + 1, item);
|
items.add(pos + 1, item);
|
||||||
vp.insert(item, pos + 1);//don't use new VerticalLayoutData(1, -1,new Margins(0))
|
vp.insert(item, pos + 1);// don't use new VerticalLayoutData(1,
|
||||||
|
// -1,new Margins(0))
|
||||||
} else {
|
} else {
|
||||||
upperItem.forceLayout();
|
upperItem.forceLayout();
|
||||||
StringItem item = new StringItem(this, objPar, true);
|
StringItem item = new StringItem(this, objPar, true);
|
||||||
items.add(item);
|
items.add(item);
|
||||||
vp.add(item);//don't use new VerticalLayoutData(-1, -1, new Margins(0))
|
vp.add(item);// don't use new VerticalLayoutData(-1, -1, new
|
||||||
|
// Margins(0))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
forceLayout();
|
forceLayout();
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
protected void forceLayout(){
|
protected void forceLayout() {
|
||||||
vp.forceLayout();
|
vp.forceLayout();
|
||||||
horiz.forceLayout();
|
horiz.forceLayout();
|
||||||
fieldContainer.forceLayout();
|
fieldContainer.forceLayout();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @param item
|
|
||||||
*/
|
|
||||||
protected void removeField(StringItem item) {
|
protected void removeField(StringItem item) {
|
||||||
items.remove(item);
|
items.remove(item);
|
||||||
|
|
||||||
|
@ -124,13 +122,10 @@ public class ListStringFld extends AbstractFld {
|
||||||
items.get(0).hideCancelButton();
|
items.get(0).hideCancelButton();
|
||||||
items.get(0).forceLayout();
|
items.get(0).forceLayout();
|
||||||
}
|
}
|
||||||
|
|
||||||
forceLayout();
|
forceLayout();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public String getValue() {
|
public String getValue() {
|
||||||
String separator = listParameter.getSeparator();
|
String separator = listParameter.getSeparator();
|
||||||
|
@ -146,17 +141,11 @@ public class ListStringFld extends AbstractFld {
|
||||||
return value;
|
return value;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public Widget getWidget() {
|
public Widget getWidget() {
|
||||||
return fieldContainer;
|
return fieldContainer;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public boolean isValid() {
|
public boolean isValid() {
|
||||||
boolean valid = false;
|
boolean valid = false;
|
||||||
|
@ -168,6 +157,4 @@ public class ListStringFld extends AbstractFld {
|
||||||
return valid;
|
return valid;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,7 +3,6 @@
|
||||||
*/
|
*/
|
||||||
package org.gcube.portlets.widgets.dataminermanagerwidget.client.parametersfield;
|
package org.gcube.portlets.widgets.dataminermanagerwidget.client.parametersfield;
|
||||||
|
|
||||||
|
|
||||||
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ListParameter;
|
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.ObjectParameter;
|
||||||
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
|
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
|
||||||
|
@ -13,8 +12,8 @@ import com.sencha.gxt.widget.core.client.form.FieldLabel;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class OperatorFieldWidget {
|
public class OperatorFieldWidget {
|
||||||
|
@ -24,46 +23,49 @@ public class OperatorFieldWidget {
|
||||||
private FieldLabel parameterLabel;
|
private FieldLabel parameterLabel;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
*
|
||||||
|
* @param parameter
|
||||||
|
* parameter
|
||||||
*/
|
*/
|
||||||
public OperatorFieldWidget(Parameter p) {
|
public OperatorFieldWidget(Parameter parameter) {
|
||||||
super();
|
super();
|
||||||
this.parameter = p;
|
this.parameter = parameter;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
if (p.getTypology() != null) {
|
if (parameter.getTypology() != null) {
|
||||||
switch (p.getTypology()) {
|
switch (parameter.getTypology()) {
|
||||||
case COLUMN:
|
case COLUMN:
|
||||||
field = new ColumnFld(p);
|
field = new ColumnFld(parameter);
|
||||||
break;
|
break;
|
||||||
case COLUMN_LIST:
|
case COLUMN_LIST:
|
||||||
field = new ColumnListFld(p);
|
field = new ColumnListFld(parameter);
|
||||||
break;
|
break;
|
||||||
case ENUM:
|
case ENUM:
|
||||||
field = new EnumFld(p);
|
field = new EnumFld(parameter);
|
||||||
break;
|
break;
|
||||||
case FILE:
|
case FILE:
|
||||||
field = new FileFld(p);
|
field = new FileFld(parameter);
|
||||||
break;
|
break;
|
||||||
case LIST:
|
case LIST:
|
||||||
field = createListField(p);
|
field = createListField(parameter);
|
||||||
break;
|
break;
|
||||||
case OBJECT:
|
case OBJECT:
|
||||||
field = createObjectField(p);
|
field = createObjectField(parameter);
|
||||||
break;
|
break;
|
||||||
case TABULAR:
|
case TABULAR:
|
||||||
field = new TabularFld(p);
|
field = new TabularFld(parameter);
|
||||||
break;
|
break;
|
||||||
case TABULAR_LIST:
|
case TABULAR_LIST:
|
||||||
field = new TabularListFld(p);
|
field = new TabularListFld(parameter);
|
||||||
break;
|
break;
|
||||||
case WKT:
|
case WKT:
|
||||||
field = new WKTFld(p);
|
field = new WKTFld(parameter);
|
||||||
break;
|
break;
|
||||||
case DATE:
|
case DATE:
|
||||||
field = new DateFld(p);
|
field = new DateFld(parameter);
|
||||||
break;
|
break;
|
||||||
case TIME:
|
case TIME:
|
||||||
field = new TimeFld(p);
|
field = new TimeFld(parameter);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
|
@ -72,12 +74,12 @@ public class OperatorFieldWidget {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (field == null) {
|
if (field == null) {
|
||||||
parameterLabel = new FieldLabel(null, p.getName());
|
parameterLabel = new FieldLabel(null, parameter.getName());
|
||||||
parameterLabel.setLabelWidth(200);
|
parameterLabel.setLabelWidth(200);
|
||||||
parameterLabel.setLabelWordWrap(true);
|
parameterLabel.setLabelWordWrap(true);
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
parameterLabel = new FieldLabel(field.getWidget(), p.getName());
|
parameterLabel = new FieldLabel(field.getWidget(), parameter.getName());
|
||||||
parameterLabel.setLabelWidth(200);
|
parameterLabel.setLabelWidth(200);
|
||||||
parameterLabel.setLabelWordWrap(true);
|
parameterLabel.setLabelWordWrap(true);
|
||||||
}
|
}
|
||||||
|
@ -107,10 +109,6 @@ public class OperatorFieldWidget {
|
||||||
return parameterLabel;
|
return parameterLabel;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param p
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
private AbstractFld createObjectField(Parameter p) {
|
private AbstractFld createObjectField(Parameter p) {
|
||||||
ObjectParameter objectParameter = (ObjectParameter) p;
|
ObjectParameter objectParameter = (ObjectParameter) p;
|
||||||
String type = objectParameter.getType();
|
String type = objectParameter.getType();
|
||||||
|
@ -128,18 +126,15 @@ public class OperatorFieldWidget {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
private AbstractFld createListField(Parameter p) {
|
private AbstractFld createListField(Parameter p) {
|
||||||
ListParameter listParameter = (ListParameter) p;
|
ListParameter listParameter = (ListParameter) p;
|
||||||
String type = listParameter.getType();
|
String type = listParameter.getType();
|
||||||
|
|
||||||
if (type.contentEquals(String.class.getName())
|
if (type.contentEquals(String.class.getName()) || type.contentEquals("STRING")) { // TODO
|
||||||
|| type.contentEquals("STRING")) { // TODO REMOVE "STRING"
|
// REMOVE
|
||||||
|
// "STRING"
|
||||||
return new ListStringFld(listParameter);
|
return new ListStringFld(listParameter);
|
||||||
} else if (type.contentEquals(Integer.class.getName())
|
} else if (type.contentEquals(Integer.class.getName()) || type.contentEquals("NUMBER")) {
|
||||||
|| type.contentEquals("NUMBER")) {
|
|
||||||
return new ListIntFld(listParameter);
|
return new ListIntFld(listParameter);
|
||||||
}
|
}
|
||||||
// } else if (type.contentEquals(Boolean.class.getName())) {
|
// } else if (type.contentEquals(Boolean.class.getName())) {
|
||||||
|
@ -153,9 +148,6 @@ public class OperatorFieldWidget {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
public void updateOperatorParameterValue() {
|
public void updateOperatorParameterValue() {
|
||||||
this.parameter.setValue(this.getFieldValue());
|
this.parameter.setValue(this.getFieldValue());
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,7 +3,6 @@
|
||||||
*/
|
*/
|
||||||
package org.gcube.portlets.widgets.dataminermanagerwidget.client.parametersfield;
|
package org.gcube.portlets.widgets.dataminermanagerwidget.client.parametersfield;
|
||||||
|
|
||||||
|
|
||||||
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ObjectParameter;
|
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.ObjectParameter;
|
||||||
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
|
import org.gcube.data.analysis.dataminermanagercl.shared.parameters.Parameter;
|
||||||
|
|
||||||
|
@ -20,8 +19,8 @@ import com.sencha.gxt.widget.core.client.form.TextField;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class StringFld extends AbstractFld {
|
public class StringFld extends AbstractFld {
|
||||||
|
@ -31,12 +30,13 @@ public class StringFld extends AbstractFld {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param parameter
|
* @param parameter
|
||||||
|
* parameter
|
||||||
*/
|
*/
|
||||||
public StringFld(Parameter parameter) {
|
public StringFld(Parameter parameter) {
|
||||||
super(parameter);
|
super(parameter);
|
||||||
|
|
||||||
ObjectParameter p = (ObjectParameter) parameter;
|
ObjectParameter p = (ObjectParameter) parameter;
|
||||||
|
|
||||||
textField = new TextField();
|
textField = new TextField();
|
||||||
textField.setValue(p.getDefaultValue());
|
textField.setValue(p.getDefaultValue());
|
||||||
|
|
||||||
|
@ -46,49 +46,41 @@ public class StringFld extends AbstractFld {
|
||||||
HtmlLayoutContainer descr;
|
HtmlLayoutContainer descr;
|
||||||
|
|
||||||
if (p.getDescription() == null) {
|
if (p.getDescription() == null) {
|
||||||
descr=new HtmlLayoutContainer("<p style='margin-left:5px !important;'></p>");
|
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'></p>");
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
//textField.setToolTip(p.getDescription());
|
// textField.setToolTip(p.getDescription());
|
||||||
descr=new HtmlLayoutContainer("<p style='margin-left:5px !important;'>"+p.getDescription()+"</p>");
|
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>" + p.getDescription() + "</p>");
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
}
|
}
|
||||||
|
|
||||||
SimpleContainer vContainer=new SimpleContainer();
|
SimpleContainer vContainer = new SimpleContainer();
|
||||||
VerticalLayoutContainer vField = new VerticalLayoutContainer();
|
VerticalLayoutContainer vField = new VerticalLayoutContainer();
|
||||||
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer(
|
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer("String Value");
|
||||||
"String Value");
|
|
||||||
typeDescription.setStylePrimaryName("workflow-parameters-description");
|
typeDescription.setStylePrimaryName("workflow-parameters-description");
|
||||||
vField.add(textField, new VerticalLayoutData(-1,-1,new Margins(0)));
|
vField.add(textField, new VerticalLayoutData(-1, -1, new Margins(0)));
|
||||||
vField.add(typeDescription, new VerticalLayoutData(-1,-1,new Margins(0)));
|
vField.add(typeDescription, new VerticalLayoutData(-1, -1, new Margins(0)));
|
||||||
vContainer.add(vField);
|
vContainer.add(vField);
|
||||||
|
|
||||||
fieldContainer = new SimpleContainer();
|
fieldContainer = new SimpleContainer();
|
||||||
HBoxLayoutContainer horiz = new HBoxLayoutContainer();
|
HBoxLayoutContainer horiz = new HBoxLayoutContainer();
|
||||||
horiz.setPack(BoxLayoutPack.START);
|
horiz.setPack(BoxLayoutPack.START);
|
||||||
horiz.setEnableOverflow(false);
|
horiz.setEnableOverflow(false);
|
||||||
|
|
||||||
|
|
||||||
horiz.add(vContainer, new BoxLayoutData(new Margins()));
|
horiz.add(vContainer, new BoxLayoutData(new Margins()));
|
||||||
horiz.add(descr, new BoxLayoutData(new Margins()));
|
horiz.add(descr, new BoxLayoutData(new Margins()));
|
||||||
|
|
||||||
fieldContainer.add(horiz);
|
fieldContainer.add(horiz);
|
||||||
fieldContainer.forceLayout();
|
fieldContainer.forceLayout();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public String getValue() {
|
public String getValue() {
|
||||||
return textField.getValue();
|
return textField.getValue();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public Widget getWidget() {
|
public Widget getWidget() {
|
||||||
return fieldContainer;
|
return fieldContainer;
|
||||||
|
@ -98,5 +90,5 @@ public class StringFld extends AbstractFld {
|
||||||
public boolean isValid() {
|
public boolean isValid() {
|
||||||
return textField.isValid();
|
return textField.isValid();
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -12,7 +12,7 @@ import com.sencha.gxt.widget.core.client.form.TextField;
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi
|
* @author Giancarlo Panichi
|
||||||
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class StringItem extends HBoxLayoutContainer {
|
public class StringItem extends HBoxLayoutContainer {
|
||||||
|
@ -22,7 +22,10 @@ public class StringItem extends HBoxLayoutContainer {
|
||||||
private TextButton removeBtn;
|
private TextButton removeBtn;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param objPar
|
*
|
||||||
|
* @param parent parent
|
||||||
|
* @param objectParameter object parameter
|
||||||
|
* @param first true if first
|
||||||
*/
|
*/
|
||||||
public StringItem(ListStringFld parent, ObjectParameter objectParameter, boolean first) {
|
public StringItem(ListStringFld parent, ObjectParameter objectParameter, boolean first) {
|
||||||
super();
|
super();
|
||||||
|
|
|
@ -33,8 +33,8 @@ import com.sencha.gxt.widget.core.client.form.TextField;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class TabItem extends HBoxLayoutContainer {
|
public class TabItem extends HBoxLayoutContainer {
|
||||||
|
@ -60,12 +60,14 @@ public class TabItem extends HBoxLayoutContainer {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @param tabularListFld
|
* @param parent
|
||||||
|
* parent
|
||||||
* @param tabularParameter
|
* @param tabularParameter
|
||||||
|
* tabular parameter
|
||||||
* @param first
|
* @param first
|
||||||
|
* true if is first
|
||||||
*/
|
*/
|
||||||
public TabItem(TabularListFld parent, TabularParameter tabularParameter,
|
public TabItem(TabularListFld parent, TabularParameter tabularParameter, boolean first) {
|
||||||
boolean first) {
|
|
||||||
super();
|
super();
|
||||||
this.parent = parent;
|
this.parent = parent;
|
||||||
this.first = first;
|
this.first = first;
|
||||||
|
@ -117,8 +119,7 @@ public class TabItem extends HBoxLayoutContainer {
|
||||||
useTabularResource();
|
useTabularResource();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
selectTRButton.setIcon(DataMinerManagerPanel.resources
|
selectTRButton.setIcon(DataMinerManagerPanel.resources.tabularResource());
|
||||||
.tabularResource());
|
|
||||||
selectTRButton.setToolTip("Use Tabular Resource");
|
selectTRButton.setToolTip("Use Tabular Resource");
|
||||||
|
|
||||||
selectTRButton2 = new TextButton("");
|
selectTRButton2 = new TextButton("");
|
||||||
|
@ -129,11 +130,9 @@ public class TabItem extends HBoxLayoutContainer {
|
||||||
useTabularResource();
|
useTabularResource();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
selectTRButton2.setIcon(DataMinerManagerPanel.resources
|
selectTRButton2.setIcon(DataMinerManagerPanel.resources.tabularResource());
|
||||||
.tabularResource());
|
|
||||||
selectTRButton2.setToolTip("Use Tabular Resource");
|
selectTRButton2.setToolTip("Use Tabular Resource");
|
||||||
|
|
||||||
|
|
||||||
selectButton = new TextButton("Select Data Set");
|
selectButton = new TextButton("Select Data Set");
|
||||||
selectButton.addSelectHandler(new SelectEvent.SelectHandler() {
|
selectButton.addSelectHandler(new SelectEvent.SelectHandler() {
|
||||||
|
|
||||||
|
@ -156,7 +155,7 @@ public class TabItem extends HBoxLayoutContainer {
|
||||||
wselectDialog.show();
|
wselectDialog.show();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
downloadButton = new TextButton("");
|
downloadButton = new TextButton("");
|
||||||
downloadButton.setIcon(DataMinerManagerPanel.resources.download());
|
downloadButton.setIcon(DataMinerManagerPanel.resources.download());
|
||||||
downloadButton.addSelectHandler(new SelectEvent.SelectHandler() {
|
downloadButton.addSelectHandler(new SelectEvent.SelectHandler() {
|
||||||
|
@ -167,7 +166,6 @@ public class TabItem extends HBoxLayoutContainer {
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
downloadButton.setToolTip("Download Data Set");
|
downloadButton.setToolTip("Download Data Set");
|
||||||
|
|
||||||
|
|
||||||
addBtn = new TextButton("");
|
addBtn = new TextButton("");
|
||||||
addBtn.setIcon(DataMinerManagerPanel.resources.add());
|
addBtn.setIcon(DataMinerManagerPanel.resources.add());
|
||||||
|
@ -191,7 +189,6 @@ public class TabItem extends HBoxLayoutContainer {
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
setPack(BoxLayoutPack.START);
|
setPack(BoxLayoutPack.START);
|
||||||
setEnableOverflow(false);
|
setEnableOverflow(false);
|
||||||
|
@ -209,7 +206,7 @@ public class TabItem extends HBoxLayoutContainer {
|
||||||
selectButton2.setVisible(false);
|
selectButton2.setVisible(false);
|
||||||
downloadButton.setVisible(false);
|
downloadButton.setVisible(false);
|
||||||
removeBtn.setVisible(!first);
|
removeBtn.setVisible(!first);
|
||||||
|
|
||||||
forceLayout();
|
forceLayout();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -228,7 +225,8 @@ public class TabItem extends HBoxLayoutContainer {
|
||||||
* "multipart/x-zip"
|
* "multipart/x-zip"
|
||||||
*/
|
*/
|
||||||
// List<String> allowedMimeTypes =
|
// List<String> allowedMimeTypes =
|
||||||
// Arrays.asList("text/csv","text/plain","text/plain; charset=ISO-8859-1");
|
// Arrays.asList("text/csv","text/plain","text/plain;
|
||||||
|
// charset=ISO-8859-1");
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* "zip"
|
* "zip"
|
||||||
|
@ -260,8 +258,7 @@ public class TabItem extends HBoxLayoutContainer {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onFailed(Throwable throwable) {
|
public void onFailed(Throwable throwable) {
|
||||||
Log.error("Error in create project: "
|
Log.error("Error in create project: " + throwable.getLocalizedMessage());
|
||||||
+ throwable.getLocalizedMessage());
|
|
||||||
UtilsGXT3.alert("Error", throwable.getLocalizedMessage());
|
UtilsGXT3.alert("Error", throwable.getLocalizedMessage());
|
||||||
throwable.printStackTrace();
|
throwable.printStackTrace();
|
||||||
}
|
}
|
||||||
|
@ -284,66 +281,56 @@ public class TabItem extends HBoxLayoutContainer {
|
||||||
|
|
||||||
private void retrieveTableInformation(Item item) {
|
private void retrieveTableInformation(Item item) {
|
||||||
Log.debug("Retrieved: " + item);
|
Log.debug("Retrieved: " + item);
|
||||||
itemDescriptionSelected = new ItemDescription(item.getId(),
|
itemDescriptionSelected = new ItemDescription(item.getId(), item.getName(), item.getOwner(), item.getPath(),
|
||||||
item.getName(), item.getOwner(), item.getPath(), item.getType()
|
item.getType().name());
|
||||||
.name());
|
|
||||||
|
|
||||||
DataMinerPortletServiceAsync.INSTANCE.retrieveTableInformation(item,
|
DataMinerPortletServiceAsync.INSTANCE.retrieveTableInformation(item, new AsyncCallback<TableItemSimple>() {
|
||||||
new AsyncCallback<TableItemSimple>() {
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onFailure(Throwable caught) {
|
public void onFailure(Throwable caught) {
|
||||||
Log.error("Error in retrieveTableInformation "
|
Log.error("Error in retrieveTableInformation " + caught.getMessage());
|
||||||
+ caught.getMessage());
|
if (caught instanceof SessionExpiredServiceException) {
|
||||||
if (caught instanceof SessionExpiredServiceException) {
|
UtilsGXT3.alert("Error", "Expired Session");
|
||||||
UtilsGXT3.alert("Error", "Expired Session");
|
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
UtilsGXT3.alert("Error",
|
UtilsGXT3.alert("Error", "Error retrieving table information: " + caught.getLocalizedMessage());
|
||||||
"Error retrieving table information: "
|
}
|
||||||
+ caught.getLocalizedMessage());
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onSuccess(TableItemSimple result) {
|
public void onSuccess(TableItemSimple result) {
|
||||||
Log.debug("Retrieved: " + result);
|
Log.debug("Retrieved: " + result);
|
||||||
selectedTableItem = result;
|
selectedTableItem = result;
|
||||||
showFieldWithFileSelection();
|
showFieldWithFileSelection();
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
private void downloadFile() {
|
private void downloadFile() {
|
||||||
if (itemDescriptionSelected != null) {
|
if (itemDescriptionSelected != null) {
|
||||||
DataMinerPortletServiceAsync.INSTANCE.getPublicLink(
|
DataMinerPortletServiceAsync.INSTANCE.getPublicLink(itemDescriptionSelected, new AsyncCallback<String>() {
|
||||||
itemDescriptionSelected, new AsyncCallback<String>() {
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onFailure(Throwable caught) {
|
public void onFailure(Throwable caught) {
|
||||||
if (caught instanceof SessionExpiredServiceException) {
|
if (caught instanceof SessionExpiredServiceException) {
|
||||||
EventBusProvider.INSTANCE
|
EventBusProvider.INSTANCE.fireEvent(new SessionExpiredEvent());
|
||||||
.fireEvent(new SessionExpiredEvent());
|
} else {
|
||||||
} else {
|
Log.error("Error downloading table: " + caught.getLocalizedMessage());
|
||||||
Log.error("Error downloading table: "
|
UtilsGXT3.alert("Error", caught.getLocalizedMessage());
|
||||||
+ caught.getLocalizedMessage());
|
}
|
||||||
UtilsGXT3.alert("Error",
|
caught.printStackTrace();
|
||||||
caught.getLocalizedMessage());
|
|
||||||
}
|
|
||||||
caught.printStackTrace();
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onSuccess(String link) {
|
public void onSuccess(String link) {
|
||||||
Log.debug("Retrieved link: " + link);
|
Log.debug("Retrieved link: " + link);
|
||||||
Window.open(link,
|
Window.open(link, itemDescriptionSelected.getName(), "");
|
||||||
itemDescriptionSelected.getName(), "");
|
}
|
||||||
}
|
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
UtilsGXT3.info("Attention", "Select a Table!");
|
UtilsGXT3.info("Attention", "Select a Table!");
|
||||||
|
@ -353,18 +340,12 @@ public class TabItem extends HBoxLayoutContainer {
|
||||||
|
|
||||||
private void useTabularResource() {
|
private void useTabularResource() {
|
||||||
Log.debug("TabularResourceData: " + tabularResourceData);
|
Log.debug("TabularResourceData: " + tabularResourceData);
|
||||||
selectedTableItem = new TableItemSimple(
|
selectedTableItem = new TableItemSimple(tabularResourceData.getTabularResourceId(),
|
||||||
tabularResourceData.getTabularResourceId(),
|
tabularResourceData.getName(), tabularResourceData.getDescription(), tabularResourceData.getType());
|
||||||
tabularResourceData.getName(),
|
|
||||||
tabularResourceData.getDescription(),
|
|
||||||
tabularResourceData.getType());
|
|
||||||
selectedTableItem.setColumns(tabularResourceData.getColumns());
|
selectedTableItem.setColumns(tabularResourceData.getColumns());
|
||||||
showFieldWithTRSelection();
|
showFieldWithTRSelection();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
private void showFieldWithTRSelection() {
|
private void showFieldWithTRSelection() {
|
||||||
try {
|
try {
|
||||||
|
|
||||||
|
|
|
@ -50,12 +50,11 @@ import com.sencha.gxt.widget.core.client.form.TextField;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class TabularFld extends AbstractFld implements
|
public class TabularFld extends AbstractFld implements HasTabularFldChangeEventHandler {
|
||||||
HasTabularFldChangeEventHandler {
|
|
||||||
|
|
||||||
private SimpleContainer fieldContainer;
|
private SimpleContainer fieldContainer;
|
||||||
private HBoxLayoutContainer horiz;
|
private HBoxLayoutContainer horiz;
|
||||||
|
@ -78,6 +77,7 @@ public class TabularFld extends AbstractFld implements
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param parameter
|
* @param parameter
|
||||||
|
* parameter
|
||||||
*/
|
*/
|
||||||
public TabularFld(Parameter parameter) {
|
public TabularFld(Parameter parameter) {
|
||||||
super(parameter);
|
super(parameter);
|
||||||
|
@ -90,7 +90,7 @@ public class TabularFld extends AbstractFld implements
|
||||||
retrieveTabularResourceInfo();
|
retrieveTabularResourceInfo();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void bind() {
|
private void bind() {
|
||||||
EventBusProvider.INSTANCE.addHandler(TabularResourceInfoEvent.TYPE,
|
EventBusProvider.INSTANCE.addHandler(TabularResourceInfoEvent.TYPE,
|
||||||
new TabularResourceInfoEvent.TabularResourceInfoEventHandler() {
|
new TabularResourceInfoEvent.TabularResourceInfoEventHandler() {
|
||||||
|
@ -120,21 +120,18 @@ public class TabularFld extends AbstractFld implements
|
||||||
|
|
||||||
SimpleContainer tabContainer = new SimpleContainer();
|
SimpleContainer tabContainer = new SimpleContainer();
|
||||||
vp = new VerticalLayoutContainer();
|
vp = new VerticalLayoutContainer();
|
||||||
//retrieveInfo();
|
// retrieveInfo();
|
||||||
init();
|
init();
|
||||||
|
|
||||||
createField(tabContainer);
|
createField(tabContainer);
|
||||||
showNoSelectionField();
|
showNoSelectionField();
|
||||||
} catch (Throwable e) {
|
} catch (Throwable e) {
|
||||||
Log.error("TabularField: " + e.getLocalizedMessage());
|
Log.error("TabularField: " + e.getLocalizedMessage());
|
||||||
UtilsGXT3.alert("Error",
|
UtilsGXT3.alert("Error", "Error creating Tabular Field: " + e.getLocalizedMessage());
|
||||||
"Error creating Tabular Field: " + e.getLocalizedMessage());
|
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
private void createField(SimpleContainer tabContainer) {
|
private void createField(SimpleContainer tabContainer) {
|
||||||
List<String> templates = tabularParameter.getTemplates();
|
List<String> templates = tabularParameter.getTemplates();
|
||||||
if (templates == null || templates.isEmpty()) {
|
if (templates == null || templates.isEmpty()) {
|
||||||
|
@ -148,8 +145,7 @@ public class TabularFld extends AbstractFld implements
|
||||||
first = false;
|
first = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
templatesList = new HtmlLayoutContainer(
|
templatesList = new HtmlLayoutContainer("<p>Suitable Data Set Templates: <br>" + list + "</p>");
|
||||||
"<p>Suitable Data Set Templates: <br>" + list + "</p>");
|
|
||||||
templatesList.addStyleName("workflow-parameters-description");
|
templatesList.addStyleName("workflow-parameters-description");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -163,14 +159,12 @@ public class TabularFld extends AbstractFld implements
|
||||||
HtmlLayoutContainer descr;
|
HtmlLayoutContainer descr;
|
||||||
|
|
||||||
if (tabularParameter.getDescription() == null) {
|
if (tabularParameter.getDescription() == null) {
|
||||||
descr = new HtmlLayoutContainer(
|
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'></p>");
|
||||||
"<p style='margin-left:5px !important;'></p>");
|
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
descr = new HtmlLayoutContainer(
|
descr = new HtmlLayoutContainer(
|
||||||
"<p style='margin-left:5px !important;'>"
|
"<p style='margin-left:5px !important;'>" + tabularParameter.getDescription() + "</p>");
|
||||||
+ tabularParameter.getDescription() + "</p>");
|
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -195,7 +189,8 @@ public class TabularFld extends AbstractFld implements
|
||||||
* "multipart/x-zip"
|
* "multipart/x-zip"
|
||||||
*/
|
*/
|
||||||
// List<String> allowedMimeTypes =
|
// List<String> allowedMimeTypes =
|
||||||
// Arrays.asList("text/csv","text/plain","text/plain; charset=ISO-8859-1");
|
// Arrays.asList("text/csv","text/plain","text/plain;
|
||||||
|
// charset=ISO-8859-1");
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* "zip"
|
* "zip"
|
||||||
|
@ -208,8 +203,7 @@ public class TabularFld extends AbstractFld implements
|
||||||
* FilterCriteria(allowedMimeTypes, allowedFileExtensions, new
|
* FilterCriteria(allowedMimeTypes, allowedFileExtensions, new
|
||||||
* HashMap<String, String>());
|
* HashMap<String, String>());
|
||||||
*/
|
*/
|
||||||
wselectDialog = new WorkspaceExplorerSelectDialog("Select CSV",
|
wselectDialog = new WorkspaceExplorerSelectDialog("Select CSV", false);
|
||||||
false);
|
|
||||||
// filterCriteria, selectableTypes);
|
// filterCriteria, selectableTypes);
|
||||||
|
|
||||||
WorskpaceExplorerSelectNotificationListener handler = new WorskpaceExplorerSelectNotificationListener() {
|
WorskpaceExplorerSelectNotificationListener handler = new WorskpaceExplorerSelectNotificationListener() {
|
||||||
|
@ -229,10 +223,8 @@ public class TabularFld extends AbstractFld implements
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onFailed(Throwable throwable) {
|
public void onFailed(Throwable throwable) {
|
||||||
Log.error("Error in create project: "
|
Log.error("Error in create project: " + throwable.getLocalizedMessage());
|
||||||
+ throwable.getLocalizedMessage());
|
UtilsGXT3.alert("Error", throwable.getLocalizedMessage());
|
||||||
UtilsGXT3.alert("Error",
|
|
||||||
throwable.getLocalizedMessage());
|
|
||||||
throwable.printStackTrace();
|
throwable.printStackTrace();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -247,17 +239,14 @@ public class TabularFld extends AbstractFld implements
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
wselectDialog
|
wselectDialog.addWorkspaceExplorerSelectNotificationListener(handler);
|
||||||
.addWorkspaceExplorerSelectNotificationListener(handler);
|
|
||||||
wselectDialog.setZIndex(XDOM.getTopZIndex());
|
wselectDialog.setZIndex(XDOM.getTopZIndex());
|
||||||
|
|
||||||
} catch (Throwable e) {
|
} catch (Throwable e) {
|
||||||
Log.error("TabularField error using WorkspaceExplorerSelectDialog: "
|
Log.error("TabularField error using WorkspaceExplorerSelectDialog: " + e.getLocalizedMessage());
|
||||||
+ e.getLocalizedMessage());
|
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
throw new Exception(
|
throw new Exception(
|
||||||
"TabularField error using WorkspaceExplorerSelectDialog: "
|
"TabularField error using WorkspaceExplorerSelectDialog: " + e.getLocalizedMessage());
|
||||||
+ e.getLocalizedMessage());
|
|
||||||
}
|
}
|
||||||
|
|
||||||
selectTRButton = new TextButton("Use Tabular Resource");
|
selectTRButton = new TextButton("Use Tabular Resource");
|
||||||
|
@ -268,8 +257,7 @@ public class TabularFld extends AbstractFld implements
|
||||||
useTabularResource();
|
useTabularResource();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
selectTRButton.setIcon(DataMinerManagerPanel.resources
|
selectTRButton.setIcon(DataMinerManagerPanel.resources.tabularResource());
|
||||||
.tabularResource());
|
|
||||||
selectTRButton.setToolTip("Use Tabular Resource");
|
selectTRButton.setToolTip("Use Tabular Resource");
|
||||||
|
|
||||||
selectTRButton2 = new TextButton("");
|
selectTRButton2 = new TextButton("");
|
||||||
|
@ -281,8 +269,7 @@ public class TabularFld extends AbstractFld implements
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
selectTRButton2.setIcon(DataMinerManagerPanel.resources
|
selectTRButton2.setIcon(DataMinerManagerPanel.resources.tabularResource());
|
||||||
.tabularResource());
|
|
||||||
selectTRButton2.setToolTip("Use Tabular Resource");
|
selectTRButton2.setToolTip("Use Tabular Resource");
|
||||||
|
|
||||||
selectButton = new TextButton("Select Data Set");
|
selectButton = new TextButton("Select Data Set");
|
||||||
|
@ -293,8 +280,7 @@ public class TabularFld extends AbstractFld implements
|
||||||
wselectDialog.show();
|
wselectDialog.show();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
selectButton.setIcon(DataMinerManagerPanel.resources
|
selectButton.setIcon(DataMinerManagerPanel.resources.folderExplore());
|
||||||
.folderExplore());
|
|
||||||
selectButton.setToolTip("Select Data Set");
|
selectButton.setToolTip("Select Data Set");
|
||||||
|
|
||||||
selectButton2 = new TextButton("");
|
selectButton2 = new TextButton("");
|
||||||
|
@ -306,8 +292,7 @@ public class TabularFld extends AbstractFld implements
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
selectButton2.setIcon(DataMinerManagerPanel.resources
|
selectButton2.setIcon(DataMinerManagerPanel.resources.folderExplore());
|
||||||
.folderExplore());
|
|
||||||
selectButton2.setToolTip("Select Another Data Set");
|
selectButton2.setToolTip("Select Another Data Set");
|
||||||
|
|
||||||
cancelButton = new TextButton("");
|
cancelButton = new TextButton("");
|
||||||
|
@ -321,9 +306,8 @@ public class TabularFld extends AbstractFld implements
|
||||||
updateListeners(null);
|
updateListeners(null);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
cancelButton.setToolTip("Cancel");
|
|
||||||
|
|
||||||
|
cancelButton.setToolTip("Cancel");
|
||||||
|
|
||||||
downloadButton = new TextButton("");
|
downloadButton = new TextButton("");
|
||||||
downloadButton.setIcon(DataMinerManagerPanel.resources.download());
|
downloadButton.setIcon(DataMinerManagerPanel.resources.download());
|
||||||
|
@ -335,7 +319,7 @@ public class TabularFld extends AbstractFld implements
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
downloadButton.setToolTip("Download Data Set");
|
downloadButton.setToolTip("Download Data Set");
|
||||||
|
|
||||||
} catch (Throwable e) {
|
} catch (Throwable e) {
|
||||||
Log.error("TabularField init: " + e.getLocalizedMessage());
|
Log.error("TabularField init: " + e.getLocalizedMessage());
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
|
@ -345,11 +329,8 @@ public class TabularFld extends AbstractFld implements
|
||||||
|
|
||||||
private void useTabularResource() {
|
private void useTabularResource() {
|
||||||
Log.debug("TabularResourceData: " + tabularResourceData);
|
Log.debug("TabularResourceData: " + tabularResourceData);
|
||||||
selectedTableItem = new TableItemSimple(
|
selectedTableItem = new TableItemSimple(tabularResourceData.getTabularResourceId(),
|
||||||
tabularResourceData.getTabularResourceId(),
|
tabularResourceData.getName(), tabularResourceData.getDescription(), tabularResourceData.getType());
|
||||||
tabularResourceData.getName(),
|
|
||||||
tabularResourceData.getDescription(),
|
|
||||||
tabularResourceData.getType());
|
|
||||||
selectedTableItem.setColumns(tabularResourceData.getColumns());
|
selectedTableItem.setColumns(tabularResourceData.getColumns());
|
||||||
selectedTableItem.setTabularResource(true);
|
selectedTableItem.setTabularResource(true);
|
||||||
showFieldWithTRSelection();
|
showFieldWithTRSelection();
|
||||||
|
@ -359,66 +340,56 @@ public class TabularFld extends AbstractFld implements
|
||||||
|
|
||||||
private void retrieveTableInformation(Item item) {
|
private void retrieveTableInformation(Item item) {
|
||||||
Log.debug("Retrieved: " + item);
|
Log.debug("Retrieved: " + item);
|
||||||
itemDescriptionSelected = new ItemDescription(item.getId(),
|
itemDescriptionSelected = new ItemDescription(item.getId(), item.getName(), item.getOwner(), item.getPath(),
|
||||||
item.getName(), item.getOwner(), item.getPath(), item.getType()
|
item.getType().name());
|
||||||
.name());
|
|
||||||
|
|
||||||
DataMinerPortletServiceAsync.INSTANCE.retrieveTableInformation(item,
|
DataMinerPortletServiceAsync.INSTANCE.retrieveTableInformation(item, new AsyncCallback<TableItemSimple>() {
|
||||||
new AsyncCallback<TableItemSimple>() {
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onFailure(Throwable caught) {
|
public void onFailure(Throwable caught) {
|
||||||
Log.error("Error in retrieveTableInformation "
|
Log.error("Error in retrieveTableInformation " + caught.getMessage());
|
||||||
+ caught.getMessage());
|
if (caught instanceof SessionExpiredServiceException) {
|
||||||
if (caught instanceof SessionExpiredServiceException) {
|
UtilsGXT3.alert("Error", "Expired Session");
|
||||||
UtilsGXT3.alert("Error", "Expired Session");
|
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
UtilsGXT3.alert("Error",
|
UtilsGXT3.alert("Error", "Error retrieving table information: " + caught.getLocalizedMessage());
|
||||||
"Error retrieving table information: "
|
}
|
||||||
+ caught.getLocalizedMessage());
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onSuccess(TableItemSimple result) {
|
public void onSuccess(TableItemSimple result) {
|
||||||
Log.debug("Retrieved: " + result);
|
Log.debug("Retrieved: " + result);
|
||||||
selectedTableItem = result;
|
selectedTableItem = result;
|
||||||
showFieldWithFileSelection();
|
showFieldWithFileSelection();
|
||||||
updateListeners(selectedTableItem);
|
updateListeners(selectedTableItem);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
private void downloadFile() {
|
private void downloadFile() {
|
||||||
if (itemDescriptionSelected != null) {
|
if (itemDescriptionSelected != null) {
|
||||||
DataMinerPortletServiceAsync.INSTANCE.getPublicLink(
|
DataMinerPortletServiceAsync.INSTANCE.getPublicLink(itemDescriptionSelected, new AsyncCallback<String>() {
|
||||||
itemDescriptionSelected, new AsyncCallback<String>() {
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onFailure(Throwable caught) {
|
public void onFailure(Throwable caught) {
|
||||||
if (caught instanceof SessionExpiredServiceException) {
|
if (caught instanceof SessionExpiredServiceException) {
|
||||||
EventBusProvider.INSTANCE
|
EventBusProvider.INSTANCE.fireEvent(new SessionExpiredEvent());
|
||||||
.fireEvent(new SessionExpiredEvent());
|
} else {
|
||||||
} else {
|
Log.error("Error downloading table: " + caught.getLocalizedMessage());
|
||||||
Log.error("Error downloading table: "
|
UtilsGXT3.alert("Error", caught.getLocalizedMessage());
|
||||||
+ caught.getLocalizedMessage());
|
}
|
||||||
UtilsGXT3.alert("Error",
|
caught.printStackTrace();
|
||||||
caught.getLocalizedMessage());
|
|
||||||
}
|
|
||||||
caught.printStackTrace();
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onSuccess(String link) {
|
public void onSuccess(String link) {
|
||||||
Log.debug("Retrieved link: " + link);
|
Log.debug("Retrieved link: " + link);
|
||||||
Window.open(link,
|
Window.open(link, itemDescriptionSelected.getName(), "");
|
||||||
itemDescriptionSelected.getName(), "");
|
}
|
||||||
}
|
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
UtilsGXT3.info("Attention", "Select a Table!");
|
UtilsGXT3.info("Attention", "Select a Table!");
|
||||||
|
@ -426,9 +397,6 @@ public class TabularFld extends AbstractFld implements
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
private void showNoSelectionField() {
|
private void showNoSelectionField() {
|
||||||
vp.clear();
|
vp.clear();
|
||||||
vp.add(selectTRButton);
|
vp.add(selectTRButton);
|
||||||
|
@ -484,35 +452,24 @@ public class TabularFld extends AbstractFld implements
|
||||||
fieldContainer.forceLayout();
|
fieldContainer.forceLayout();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public String getValue() {
|
public String getValue() {
|
||||||
return (selectedTableItem == null) ? null : selectedTableItem.getId();
|
return (selectedTableItem == null) ? null : selectedTableItem.getId();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public Widget getWidget() {
|
public Widget getWidget() {
|
||||||
return fieldContainer;
|
return fieldContainer;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public boolean isValid() {
|
public boolean isValid() {
|
||||||
return (selectedTableItem != null);
|
return (selectedTableItem != null);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public HandlerRegistration addTabularFldChangeEventHandler(
|
public HandlerRegistration addTabularFldChangeEventHandler(TabularFldChangeEventHandler handler) {
|
||||||
TabularFldChangeEventHandler handler) {
|
return fieldContainer.addHandler(handler, TabularFldChangeEvent.getType());
|
||||||
return fieldContainer.addHandler(handler,
|
|
||||||
TabularFldChangeEvent.getType());
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -22,8 +22,8 @@ import com.sencha.gxt.widget.core.client.container.VerticalLayoutContainer;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class TabularListFld extends AbstractFld {
|
public class TabularListFld extends AbstractFld {
|
||||||
|
@ -37,6 +37,7 @@ public class TabularListFld extends AbstractFld {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param parameter
|
* @param parameter
|
||||||
|
* parameter
|
||||||
*/
|
*/
|
||||||
public TabularListFld(Parameter parameter) {
|
public TabularListFld(Parameter parameter) {
|
||||||
super(parameter);
|
super(parameter);
|
||||||
|
@ -81,8 +82,8 @@ public class TabularListFld extends AbstractFld {
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
} else {
|
} else {
|
||||||
/* listContainer.setToolTip(listParameter.getDescription()); */
|
/* listContainer.setToolTip(listParameter.getDescription()); */
|
||||||
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>"
|
descr = new HtmlLayoutContainer(
|
||||||
+ tabularListParameter.getDescription() + "</p>");
|
"<p style='margin-left:5px !important;'>" + tabularListParameter.getDescription() + "</p>");
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -97,12 +98,9 @@ public class TabularListFld extends AbstractFld {
|
||||||
protected void addField(TabItem upperItem) {
|
protected void addField(TabItem upperItem) {
|
||||||
try {
|
try {
|
||||||
|
|
||||||
TabularParameter tabPar = new TabularParameter(
|
TabularParameter tabPar = new TabularParameter(tabularListParameter.getName(),
|
||||||
tabularListParameter.getName(),
|
tabularListParameter.getDescription(), null, tabularListParameter.getTemplates(),
|
||||||
tabularListParameter.getDescription(), null,
|
tabularListParameter.getDefaultMimeType(), tabularListParameter.getSupportedMimeTypes());
|
||||||
tabularListParameter.getTemplates(),
|
|
||||||
tabularListParameter.getDefaultMimeType(),
|
|
||||||
tabularListParameter.getSupportedMimeTypes());
|
|
||||||
|
|
||||||
if (upperItem == null) {
|
if (upperItem == null) {
|
||||||
TabItem item = new TabItem(this, tabPar, true);
|
TabItem item = new TabItem(this, tabPar, true);
|
||||||
|
@ -114,18 +112,20 @@ public class TabularListFld extends AbstractFld {
|
||||||
int pos = items.indexOf(upperItem);
|
int pos = items.indexOf(upperItem);
|
||||||
if (pos == 0) {
|
if (pos == 0) {
|
||||||
upperItem.showCancelButton();
|
upperItem.showCancelButton();
|
||||||
|
|
||||||
TabItem item = new TabItem(this, tabPar, false);
|
TabItem item = new TabItem(this, tabPar, false);
|
||||||
items.add(1, item);
|
items.add(1, item);
|
||||||
vp.insert(item, 1);// don't use new
|
vp.insert(item, 1);// don't use new
|
||||||
// VerticalLayoutData(-1, -1,new
|
// VerticalLayoutData(-1, -1,new
|
||||||
// Margins(0))
|
// Margins(0))
|
||||||
} else {
|
} else {
|
||||||
//upperItem.forceLayout();
|
// upperItem.forceLayout();
|
||||||
TabItem item = new TabItem(this, tabPar, false);
|
TabItem item = new TabItem(this, tabPar, false);
|
||||||
items.add(pos+1,item);
|
items.add(pos + 1, item);
|
||||||
vp.insert(item,pos+1);// don't use new VerticalLayoutData(-1, -1, new
|
vp.insert(item, pos + 1);// don't use new
|
||||||
// Margins(0))
|
// VerticalLayoutData(-1, -1,
|
||||||
|
// new
|
||||||
|
// Margins(0))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -137,24 +137,17 @@ public class TabularListFld extends AbstractFld {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
* @param item
|
|
||||||
*/
|
|
||||||
protected void removeField(TabItem item) {
|
protected void removeField(TabItem item) {
|
||||||
items.remove(item);
|
items.remove(item);
|
||||||
|
|
||||||
if (items.size() == 1) {
|
if (items.size() == 1) {
|
||||||
TabItem topItem=items.get(0);
|
TabItem topItem = items.get(0);
|
||||||
topItem.hideCancelButton();
|
topItem.hideCancelButton();
|
||||||
}
|
}
|
||||||
vp.remove(item);
|
vp.remove(item);
|
||||||
forceLayout();
|
forceLayout();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
protected void forceLayout() {
|
protected void forceLayout() {
|
||||||
vp.forceLayout();
|
vp.forceLayout();
|
||||||
listContainer.forceLayout();
|
listContainer.forceLayout();
|
||||||
|
@ -162,9 +155,6 @@ public class TabularListFld extends AbstractFld {
|
||||||
fieldContainer.forceLayout();
|
fieldContainer.forceLayout();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public String getValue() {
|
public String getValue() {
|
||||||
String separator = tabularListParameter.getSeparator();
|
String separator = tabularListParameter.getSeparator();
|
||||||
|
@ -181,9 +171,6 @@ public class TabularListFld extends AbstractFld {
|
||||||
return value;
|
return value;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public Widget getWidget() {
|
public Widget getWidget() {
|
||||||
return fieldContainer;
|
return fieldContainer;
|
||||||
|
|
|
@ -24,8 +24,8 @@ import com.sencha.gxt.widget.core.client.form.TimeField;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class TimeFld extends AbstractFld {
|
public class TimeFld extends AbstractFld {
|
||||||
|
@ -36,6 +36,7 @@ public class TimeFld extends AbstractFld {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param parameter
|
* @param parameter
|
||||||
|
* parameter
|
||||||
*/
|
*/
|
||||||
public TimeFld(Parameter parameter) {
|
public TimeFld(Parameter parameter) {
|
||||||
super(parameter);
|
super(parameter);
|
||||||
|
@ -60,26 +61,21 @@ public class TimeFld extends AbstractFld {
|
||||||
HtmlLayoutContainer descr;
|
HtmlLayoutContainer descr;
|
||||||
|
|
||||||
if (p.getDescription() == null) {
|
if (p.getDescription() == null) {
|
||||||
descr = new HtmlLayoutContainer(
|
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'></p>");
|
||||||
"<p style='margin-left:5px !important;'></p>");
|
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
// textField.setToolTip(p.getDescription());
|
// textField.setToolTip(p.getDescription());
|
||||||
descr = new HtmlLayoutContainer(
|
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>" + p.getDescription() + "</p>");
|
||||||
"<p style='margin-left:5px !important;'>"
|
|
||||||
+ p.getDescription() + "</p>");
|
|
||||||
descr.addStyleName("workflow-fieldDescription");
|
descr.addStyleName("workflow-fieldDescription");
|
||||||
}
|
}
|
||||||
|
|
||||||
SimpleContainer vContainer = new SimpleContainer();
|
SimpleContainer vContainer = new SimpleContainer();
|
||||||
VerticalLayoutContainer vField = new VerticalLayoutContainer();
|
VerticalLayoutContainer vField = new VerticalLayoutContainer();
|
||||||
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer(
|
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer("Time Value");
|
||||||
"Time Value");
|
|
||||||
typeDescription.setStylePrimaryName("workflow-parameters-description");
|
typeDescription.setStylePrimaryName("workflow-parameters-description");
|
||||||
vField.add(timeField, new VerticalLayoutData(-1, -1, new Margins(0)));
|
vField.add(timeField, new VerticalLayoutData(-1, -1, new Margins(0)));
|
||||||
vField.add(typeDescription, new VerticalLayoutData(-1, -1, new Margins(
|
vField.add(typeDescription, new VerticalLayoutData(-1, -1, new Margins(0)));
|
||||||
0)));
|
|
||||||
vContainer.add(vField);
|
vContainer.add(vField);
|
||||||
|
|
||||||
fieldContainer = new SimpleContainer();
|
fieldContainer = new SimpleContainer();
|
||||||
|
@ -95,18 +91,12 @@ public class TimeFld extends AbstractFld {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public String getValue() {
|
public String getValue() {
|
||||||
String timeS = timeFormat.format(timeField.getCurrentValue());
|
String timeS = timeFormat.format(timeField.getCurrentValue());
|
||||||
return timeS;
|
return timeS;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public Widget getWidget() {
|
public Widget getWidget() {
|
||||||
return fieldContainer;
|
return fieldContainer;
|
||||||
|
|
|
@ -30,8 +30,8 @@ import com.sencha.gxt.widget.core.client.form.TextField;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class WKTFld extends AbstractFld {
|
public class WKTFld extends AbstractFld {
|
||||||
|
@ -52,7 +52,7 @@ public class WKTFld extends AbstractFld {
|
||||||
private TextField selectedAreaField;
|
private TextField selectedAreaField;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param parameter
|
* @param parameter parameter
|
||||||
*/
|
*/
|
||||||
public WKTFld(Parameter parameter) {
|
public WKTFld(Parameter parameter) {
|
||||||
super(parameter);
|
super(parameter);
|
||||||
|
|
|
@ -12,7 +12,7 @@ import com.sencha.gxt.data.shared.PropertyAccess;
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi
|
* @author Giancarlo Panichi
|
||||||
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public interface ColumnItemProperties extends PropertyAccess<ColumnItem> {
|
public interface ColumnItemProperties extends PropertyAccess<ColumnItem> {
|
||||||
|
|
|
@ -11,7 +11,7 @@ import com.sencha.gxt.data.shared.PropertyAccess;
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi
|
* @author Giancarlo Panichi
|
||||||
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public interface ColumnItemPropertiesCombo extends PropertyAccess<ColumnItem> {
|
public interface ColumnItemPropertiesCombo extends PropertyAccess<ColumnItem> {
|
||||||
|
|
|
@ -7,8 +7,8 @@ import com.google.gwt.resources.client.ImageResource;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public interface Resources extends ClientBundle {
|
public interface Resources extends ClientBundle {
|
||||||
|
|
|
@ -20,8 +20,8 @@ import com.google.gwt.user.client.rpc.AsyncCallback;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public interface DataMinerPortletServiceAsync {
|
public interface DataMinerPortletServiceAsync {
|
||||||
|
|
|
@ -10,8 +10,8 @@ import org.gcube.data.analysis.dataminermanagercl.shared.data.ColumnItem;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi email: <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class TabularResourceData implements Serializable {
|
public class TabularResourceData implements Serializable {
|
||||||
|
|
|
@ -2,8 +2,8 @@ package org.gcube.portlets.widgets.dataminermanagerwidget.client.type;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public enum DataMinerWorkAreaElementType {
|
public enum DataMinerWorkAreaElementType {
|
||||||
|
|
|
@ -2,8 +2,8 @@ package org.gcube.portlets.widgets.dataminermanagerwidget.client.type;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi"
|
* @author Giancarlo Panichi
|
||||||
* <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public enum DataMinerWorkAreaEventType {
|
public enum DataMinerWorkAreaEventType {
|
||||||
|
|
|
@ -2,8 +2,8 @@ package org.gcube.portlets.widgets.dataminermanagerwidget.client.type;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author "Giancarlo Panichi" <a
|
* @author Giancarlo Panichi
|
||||||
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public enum DataMinerWorkAreaRegionType {
|
public enum DataMinerWorkAreaRegionType {
|
||||||
|
|
|
@ -3,7 +3,7 @@ package org.gcube.portlets.widgets.dataminermanagerwidget.client.type;
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @author Giancarlo Panichi
|
* @author Giancarlo Panichi
|
||||||
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public enum DataMinerWorkAreaRequestEventType {
|
public enum DataMinerWorkAreaRequestEventType {
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue