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/user/data-miner-manager@148553 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
Giancarlo Panichi 2017-05-12 09:58:15 +00:00
parent 135edd837e
commit 5497d22d2f
170 changed files with 1175 additions and 1187 deletions

View File

@ -1,20 +1,28 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" output="target/data-miner-manager-1.4.0-SNAPSHOT/WEB-INF/classes" path="src/main/java">
<classpathentry kind="src" output="target/data-miner-manager-1.5.0-SNAPSHOT/WEB-INF/classes" path="src/main/java">
<attributes>
<attribute name="optional" value="true"/>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry including="**/*.java" kind="src" path="src/main/resources"/>
<classpathentry excluding="**" kind="src" output="target/data-miner-manager-1.5.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">
<attributes>
<attribute name="optional" value="true"/>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry including="**/*.java" 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">
<classpathentry excluding="**" kind="src" output="target/test-classes" path="src/test/resources">
<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>
<attribute name="maven.pomderived" value="true"/>
</attributes>
@ -26,5 +34,5 @@
</attributes>
</classpathentry>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="output" path="target/data-miner-manager-1.4.0-SNAPSHOT/WEB-INF/classes"/>
<classpathentry kind="output" path="target/data-miner-manager-1.5.0-SNAPSHOT/WEB-INF/classes"/>
</classpath>

View File

@ -1,4 +1,8 @@
<ReleaseNotes>
<Changeset component="org.gcube.portlets-user.data-miner-manager.1-5-0"
date="2016-06-12">
<Change>Support Java 8 compatibility [ticket #8471]</Change>
</Changeset>
<Changeset component="org.gcube.portlets-user.data-miner-manager.1-4-0"
date="2016-02-15">
<Change>Fixed load balancing [ticket #7576]</Change>

12
pom.xml
View File

@ -12,7 +12,7 @@
<groupId>org.gcube.portlets.user</groupId>
<artifactId>data-miner-manager</artifactId>
<version>1.4.0-SNAPSHOT</version>
<version>1.5.0-SNAPSHOT</version>
<packaging>war</packaging>
<name>data-miner-manager</name>
@ -41,8 +41,10 @@
<configDirectory>config</configDirectory>
<!-- Java Version -->
<javaVersion>1.7</javaVersion>
<!-- Java -->
<maven.compiler.source>1.7</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
<!-- GWT configuration -->
<gwtVersion>2.6.1</gwtVersion>
@ -425,8 +427,8 @@
<artifactId>maven-compiler-plugin</artifactId>
<version>2.3.2</version>
<configuration>
<source>${javaVersion}</source>
<target>${javaVersion}</target>
<source>${maven.compiler.source}</source>
<target>${maven.compiler.target}</target>
</configuration>
</plugin>

View File

@ -47,8 +47,8 @@ import com.sencha.gxt.widget.core.client.event.HideEvent.HideHandler;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class DataMinerManagerController {

View File

@ -21,8 +21,8 @@ import com.google.gwt.user.client.ui.Image;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class Header extends HorizontalPanel {

View File

@ -22,8 +22,8 @@ import com.sencha.gxt.widget.core.client.container.VerticalLayoutContainer.Verti
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class HomePanel extends SimpleContainer {

View File

@ -15,8 +15,8 @@ import com.sencha.gxt.widget.core.client.container.Viewport.ViewportAppearance;
/**
*
* @author "Giancarlo Panichi"
* <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class PortalViewport extends SimpleContainer {

View File

@ -8,8 +8,8 @@ import com.google.gwt.event.shared.SimpleEventBus;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class EventBusProvider {

View File

@ -13,8 +13,8 @@ import com.sencha.gxt.widget.core.client.form.TextField;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ComputationValueFileListPanel extends SimpleContainer {

View File

@ -14,8 +14,8 @@ import com.sencha.gxt.widget.core.client.event.SelectEvent;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ComputationValueFilePanel extends SimpleContainer {

View File

@ -14,8 +14,8 @@ import com.sencha.gxt.widget.core.client.event.SelectEvent;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ComputationValueImagePanel extends SimpleContainer {

View File

@ -51,8 +51,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ComputationsExecutedPanel extends FramedPanel {

View File

@ -20,8 +20,8 @@ import com.sencha.gxt.widget.core.client.container.SimpleContainer;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ComputationsPanel extends SimpleContainer {

View File

@ -2,8 +2,8 @@ package org.gcube.portlets.user.dataminermanager.client.computations;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public enum ComputationsPropertiesType {

View File

@ -26,8 +26,8 @@ import com.sencha.gxt.widget.core.client.form.TextField;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ComputationsViewerPanel extends FramedPanel {

View File

@ -3,8 +3,8 @@ package org.gcube.portlets.user.dataminermanager.client.custom;
/**
* Fix for z-index bug between GXT3 and GXT2
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class Gxt2ZIndexXDOM extends

View File

@ -5,8 +5,8 @@ import com.sencha.gxt.widget.core.client.ProgressBar;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class GreenProgressBar extends ProgressBar {

View File

@ -19,8 +19,8 @@ import com.sencha.gxt.core.client.util.Format;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class GreenProgressBarAppearance implements ProgressBarAppearance {

View File

@ -5,8 +5,8 @@ import com.sencha.gxt.widget.core.client.ProgressBar;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class OrangeProgressBar extends ProgressBar {

View File

@ -19,8 +19,8 @@ import com.sencha.gxt.core.client.util.Format;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class OrangeProgressBarAppearance implements ProgressBarAppearance {

View File

@ -5,8 +5,8 @@ import com.sencha.gxt.widget.core.client.ProgressBar;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class RedProgressBar extends ProgressBar {

View File

@ -19,8 +19,8 @@ import com.sencha.gxt.core.client.util.Format;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class RedProgressBarAppearance implements ProgressBarAppearance {

View File

@ -11,8 +11,8 @@ import com.sencha.gxt.widget.core.client.container.SimpleContainer;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class DataSpacePanel extends SimpleContainer {

View File

@ -2,8 +2,8 @@ package org.gcube.portlets.user.dataminermanager.client.dataspace;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public enum DataSpacePropertiesType {

View File

@ -48,8 +48,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class InputDataSetsPanel extends FramedPanel {

View File

@ -48,8 +48,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class OutputDataSetsPanel extends FramedPanel {

View File

@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
* Cancel Computation Request Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class CancelComputationExecutionRequestEvent

View File

@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
* Cancel Execution From Computations Request Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class CancelExecutionFromComputationsRequestEvent

View File

@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
* Computation Data Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ComputationDataEvent extends

View File

@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
* Output Show Request Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ComputationDataRequestEvent

View File

@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
* Computation Ready Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ComputationReadyEvent extends

View File

@ -13,8 +13,8 @@ import com.google.gwt.event.shared.HasHandlers;
* Data Miner Work Area Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class DataMinerWorkAreaEvent extends

View File

@ -12,8 +12,8 @@ import com.google.gwt.event.shared.HasHandlers;
* Data Miner Work Area Request Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class DataMinerWorkAreaRequestEvent

View File

@ -12,8 +12,8 @@ import com.google.gwt.event.shared.HasHandlers;
* Delete Item Request Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class DeleteItemRequestEvent extends

View File

@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
* Menu Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class MenuEvent extends

View File

@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
* Menu Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class MenuSwitchEvent extends

View File

@ -12,8 +12,8 @@ import com.google.gwt.event.shared.HasHandlers;
* Operators Classification Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class OperatorsClassificationEvent

View File

@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
* Operators Classification Request Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class OperatorsClassificationRequestEvent

View File

@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
* Output Data Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class OutputDataEvent extends

View File

@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
* Output Data Request Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class OutputDataRequestEvent extends

View File

@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
* Refresh DataMiner Work Area Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class RefreshDataMinerWorkAreaEvent extends

View File

@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
* Resubmit Computation Execution Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ResubmitComputationExecutionEvent

View File

@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
* Resubmit Computation Execution Request Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ResubmitComputationExecutionRequestEvent

View File

@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
* Session Expired Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class SessionExpiredEvent extends GwtEvent<SessionExpiredEvent.SessionExpiredEventHandler> {

View File

@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
* Start Computation Execution Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class StartComputationExecutionEvent

View File

@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
* Start Computation Execution Request Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class StartComputationExecutionRequestEvent

View File

@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
* Start Computation Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class TabularFldChangeEvent extends

View File

@ -11,8 +11,8 @@ import com.google.gwt.event.shared.HasHandlers;
* User Interface State Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class UIStateEvent extends GwtEvent<UIStateEvent.UIStateEventHandler> {

View File

@ -12,8 +12,8 @@ import com.google.gwt.event.shared.HasHandlers;
* WPS Menu Event
*
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class WPSMenuEvent extends

View File

@ -25,8 +25,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ComputationExecutionPanel extends FramedPanel {

View File

@ -34,8 +34,8 @@ import com.sencha.gxt.widget.core.client.container.VerticalLayoutContainer.Verti
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ComputationOutputPanel extends SimpleContainer {

View File

@ -28,8 +28,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ComputationPanel extends FramedPanel implements HasComputationReadyEventHandler

View File

@ -47,8 +47,8 @@ import com.sencha.gxt.widget.core.client.form.FormPanel;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ComputationParametersPanel extends SimpleContainer {
@ -199,7 +199,7 @@ public class ComputationParametersPanel extends SimpleContainer {
*/
/**
* @param parametersPanel
* @param parameter parametersPanel
*/
private void loadOperatorParameters() {
DataMinerPortletServiceAsync.INSTANCE.getParameters(operator,

View File

@ -33,8 +33,8 @@ import com.sencha.gxt.widget.core.client.info.Info;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ComputationStatusPanel extends SimpleContainer {
@ -49,6 +49,7 @@ public class ComputationStatusPanel extends SimpleContainer {
/**
*
* @param operatorName operator name
*/
public ComputationStatusPanel(String operatorName) {
super();

View File

@ -9,8 +9,8 @@ import com.sencha.gxt.widget.core.client.form.TextArea;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class EquivalentRequestDialog extends Dialog {

View File

@ -10,8 +10,8 @@ import com.sencha.gxt.widget.core.client.container.SimpleContainer;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ExperimentPanel extends SimpleContainer implements

View File

@ -22,7 +22,7 @@ import com.sencha.gxt.widget.core.client.tips.ToolTipConfig;
/**
*
* @author Giancarlo Panichi
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
*
*
*/
public class OperatorCategoryPanel extends SimpleContainer {
@ -34,37 +34,36 @@ public class OperatorCategoryPanel extends SimpleContainer {
private OperatorCategory category;
private HtmlLayoutContainer categoryHtml;
private VerticalLayoutContainer v;
/**
*
* @param handler
* @param cat
* operator panel handler
* @param operatorCategory
* operator category
*/
public OperatorCategoryPanel(OperatorsPanelHandler handler, OperatorCategory cat) {
super();
public OperatorCategoryPanel(OperatorsPanelHandler handler, OperatorCategory operatorCategory) {
super();
this.handler = handler;
this.category = cat;
this.category = operatorCategory;
create();
}
public OperatorCategory getCategory() {
return category;
}
private void create(){
v=new VerticalLayoutContainer();
private void create() {
v = new VerticalLayoutContainer();
add(v);
// set category info
categoryHtml = new HtmlLayoutContainer(category.getName() + " <span class='counter'>("+category.getOperators().size()+")</span>");
categoryHtml = new HtmlLayoutContainer(
category.getName() + " <span class='counter'>(" + category.getOperators().size() + ")</span>");
categoryHtml.addStyleName("categoryItem");
categoryHtml.addStyleName("categoryItem-Collapsed");
ToolTipConfig tooltipConfig = createToolTip(category);
categoryHtml.setToolTipConfig(tooltipConfig);
addDomHandler(new ClickHandler() {
@Override
@ -74,7 +73,7 @@ public class OperatorCategoryPanel extends SimpleContainer {
}
}, ClickEvent.getType());
v.add(categoryHtml);
}
@ -85,18 +84,17 @@ public class OperatorCategoryPanel extends SimpleContainer {
*/
private ToolTipConfig createToolTip(OperatorCategory cat) {
ToolTipConfig tooltipConfig = new ToolTipConfig();
tooltipConfig.setTitleHtml("<br>&nbsp;&nbsp;"+cat.getName());
tooltipConfig.setTitleHtml("<br>&nbsp;&nbsp;" + cat.getName());
tooltipConfig.setMouseOffsetX(0);
tooltipConfig.setMouseOffsetY(0);
tooltipConfig.setAnchor(Side.LEFT);
tooltipConfig.setDismissDelay(5000);
tooltipConfig.setBodyHtml(
getTooltipTemplate(GWT.getModuleBaseURL(), cat.getId(), cat.hasImage(), cat.getDescription())
);
getTooltipTemplate(GWT.getModuleBaseURL(), cat.getId(), cat.hasImage(), cat.getDescription()));
tooltipConfig.setMaxWidth(TOOLTIP_WIDTH);
return tooltipConfig;
}
/**
*
* @param base
@ -105,15 +103,12 @@ public class OperatorCategoryPanel extends SimpleContainer {
* @param description
* @return
*/
private String getTooltipTemplate(String base, String id, boolean hasImage, String description){
String html =
"<div class='categoryItemTooltip'>"+
"<img src='" + base + "../images/categories/"+(hasImage ? id : "DEFAULT_IMAGE")+".png' >"+
Format.ellipse(description, 100)+
"</div>";
return html;
private String getTooltipTemplate(String base, String id, boolean hasImage, String description) {
String html = "<div class='categoryItemTooltip'>" + "<img src='" + base + "../images/categories/"
+ (hasImage ? id : "DEFAULT_IMAGE") + ".png' >" + Format.ellipse(description, 100) + "</div>";
return html;
};
/**
*
*/
@ -131,7 +126,7 @@ public class OperatorCategoryPanel extends SimpleContainer {
categoryHtml.removeStyleName("categoryItem-Expanded");
categoryHtml.addStyleName("categoryItem-Collapsed");
for (OperatorPanel op: this.operatorPanelsList)
for (OperatorPanel op : this.operatorPanelsList)
v.remove(op);
isCollapsed = true;
forceLayout();
@ -141,7 +136,7 @@ public class OperatorCategoryPanel extends SimpleContainer {
*
*/
private void expand() {
if (operatorPanelsList==null) {
if (operatorPanelsList == null) {
// init operator panels
operatorPanelsList = new ArrayList<OperatorPanel>();
for (Operator op : category.getOperators()) {
@ -149,29 +144,27 @@ public class OperatorCategoryPanel extends SimpleContainer {
operatorPanelsList.add(operatorPanel);
}
}
categoryHtml.removeStyleName("categoryItem-Collapsed");
categoryHtml.addStyleName("categoryItem-Expanded");
for (OperatorPanel op: this.operatorPanelsList)
for (OperatorPanel op : this.operatorPanelsList)
v.add(op);
isCollapsed = false;
forceLayout();
}
public void setDefaultOperator(){
public void setDefaultOperator() {
expand();
}
public void setOperatorDefault(Operator operatorDefault) {
expand();
for(OperatorPanel opPanel:operatorPanelsList){
if(opPanel.getOperator().compareTo(operatorDefault)==0){
for (OperatorPanel opPanel : operatorPanelsList) {
if (opPanel.getOperator().compareTo(operatorDefault) == 0) {
opPanel.setAsTheDefaultOperator();
break;
}
}
}
}

View File

@ -17,7 +17,7 @@ import com.sencha.gxt.widget.core.client.tips.ToolTipConfig;
/**
*
* @author Giancarlo Panichi
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
*
*
*/
public class OperatorPanel extends SimpleContainer {
@ -34,7 +34,9 @@ public class OperatorPanel extends SimpleContainer {
/**
*
* @param operator
* operator
* @param handler
* operator panel handler
*/
public OperatorPanel(Operator operator, OperatorsPanelHandler handler) {
super();
@ -54,7 +56,7 @@ public class OperatorPanel extends SimpleContainer {
public void onClick(ClickEvent event) {
event.stopPropagation();
handler.addOperator(OperatorPanel.this, operator);
}
}, ClickEvent.getType());
@ -62,30 +64,31 @@ public class OperatorPanel extends SimpleContainer {
titleHtml = new HTML(operator.getName());
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");
vert=new VerticalLayoutContainer();
vert = new VerticalLayoutContainer();
vert.add(titleHtml, new VerticalLayoutData(1, -1, new Margins(0)));
vert.add(descriptionHtml, new VerticalLayoutData(1, -1, new Margins(0)));
add(vert);
ToolTipConfig tooltipConfig = createToolTip(operator);
setToolTipConfig(tooltipConfig);
}
/**
*
* @return
* @return operator
*/
public Operator getOperator() {
return operator;
}
/**
* @return
* @return tooltip config
*/
private ToolTipConfig createToolTip(Operator op) {
ToolTipConfig tooltipConfig = new ToolTipConfig();
@ -94,27 +97,17 @@ public class OperatorPanel extends SimpleContainer {
tooltipConfig.setMouseOffsetY(0);
tooltipConfig.setAnchor(Side.LEFT);
tooltipConfig.setDismissDelay(5000);
tooltipConfig.setBodyHtml(getTooltipTemplate(GWT.getModuleBaseURL(),
op.getId(), op.hasImage(), op.getDescription()));
tooltipConfig.setBodyHtml(
getTooltipTemplate(GWT.getModuleBaseURL(), op.getId(), op.hasImage(), op.getDescription()));
// config.setCloseable(true);
tooltipConfig.setMaxWidth(TOOLTIP_WIDTH);
return tooltipConfig;
}
/**
*
* @param base
* @param id
* @param hasImage
* @param description
* @return
*/
private String getTooltipTemplate(String base, String id, boolean hasImage,
String description) {
String template = "<div class='categoryItemTooltip'>" + "<img src='"
+ base + "../images/operators/"
+ (hasImage ? id : "DEFAULT_IMAGE") + ".png' >" + Format.ellipse(description, TOOLTIP_DESCRIPTION_LENGHT)
+ "</div>";
private String getTooltipTemplate(String base, String id, boolean hasImage, String description) {
String template = "<div class='categoryItemTooltip'>" + "<img src='" + base + "../images/operators/"
+ (hasImage ? id : "DEFAULT_IMAGE") + ".png' >"
+ Format.ellipse(description, TOOLTIP_DESCRIPTION_LENGHT) + "</div>";
return template;
};
@ -127,8 +120,11 @@ public class OperatorPanel extends SimpleContainer {
this.removeStyleName("operatorPanel-selected");
// titleHtml.removeStyleName("operatorPanel-title-selected");
}
public void setAsTheDefaultOperator(){
/**
* Set as the default operator
*/
public void setAsTheDefaultOperator() {
handler.addOperator(OperatorPanel.this, operator);
}

View File

@ -42,8 +42,8 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class OperatorsPanel extends FramedPanel {
@ -73,6 +73,7 @@ public class OperatorsPanel extends FramedPanel {
/**
*
* @param handler operators panel handler
*/
public OperatorsPanel(OperatorsPanelHandler handler) {
super();

View File

@ -8,14 +8,16 @@ import org.gcube.portlets.user.dataminermanager.shared.process.Operator;
/**
*
* @author Giancarlo Panichi
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
*
*
*/
public interface OperatorsPanelHandler {
/**
* @param operatorPanel
* @param operatorPanel
* operator panel
* @param operator
* operator
*/
void addOperator(OperatorPanel operatorPanel, Operator operator);

View File

@ -15,8 +15,8 @@ import com.sencha.gxt.widget.core.client.TabPanel;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class WorkflowPanel extends TabPanel {

View File

@ -5,8 +5,8 @@ import com.sencha.gxt.widget.core.client.box.AutoProgressMessageBox;
/**
*
* @author giancarlo email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class StatusMonitor extends AutoProgressMessageBox {
@ -19,7 +19,9 @@ public class StatusMonitor extends AutoProgressMessageBox {
/**
*
* @param headingHtml
* head
* @param messageHtml
* message
*/
public StatusMonitor(SafeHtml headingHtml, SafeHtml messageHtml) {
super(headingHtml, messageHtml);
@ -29,6 +31,7 @@ public class StatusMonitor extends AutoProgressMessageBox {
/**
*
* @param headingHtml
* head
*/
public StatusMonitor(SafeHtml headingHtml) {
super(headingHtml);
@ -38,7 +41,9 @@ public class StatusMonitor extends AutoProgressMessageBox {
/**
*
* @param headingHtml
* head
* @param messageHtml
* message
*/
public StatusMonitor(String headingHtml, String messageHtml) {
super(headingHtml, messageHtml);
@ -48,6 +53,7 @@ public class StatusMonitor extends AutoProgressMessageBox {
/**
*
* @param headingHtml
* head
*/
public StatusMonitor(String headingHtml) {
super(headingHtml);

View File

@ -10,44 +10,49 @@ import com.google.gwt.user.client.ui.Widget;
/**
*
* @author Giancarlo Panichi
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
*
*
*/
public abstract class AbstractFld {
protected Parameter parameter;
public abstract String getValue();
public abstract String getValue();
public abstract Widget getWidget();
/**
*
* @param parameter parameter
* parameter
*/
public AbstractFld(Parameter parameter) {
this.parameter = parameter;
}
/**
* @return the operator
*
* @return Parameter
*/
public Parameter getParameter() {
return parameter;
}
/**
* @param operator the operator to set
*
* @param parameter parameter
* parameter
*/
public void setParameter(Parameter parameter) {
this.parameter = parameter;
}
/**
*
* @return
* @return true if is valid
*/
public boolean isValid() {
return true;
}
}

View File

@ -19,8 +19,8 @@ import com.sencha.gxt.widget.core.client.form.SimpleComboBox;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class BooleanFld extends AbstractFld {
@ -30,6 +30,7 @@ public class BooleanFld extends AbstractFld {
/**
* @param parameter
* parameter
*/
public BooleanFld(Parameter parameter) {
super(parameter);
@ -48,14 +49,14 @@ public class BooleanFld extends AbstractFld {
listBox.setEditable(false);
listBox.setTriggerAction(TriggerAction.ALL);
if (p.getDefaultValue() != null&& !p.getDefaultValue().isEmpty()) {
Boolean b=Boolean.valueOf(p.getDefaultValue());
if(b){
if (p.getDefaultValue() != null && !p.getDefaultValue().isEmpty()) {
Boolean b = Boolean.valueOf(p.getDefaultValue());
if (b) {
listBox.setValue("true");
} else {
listBox.setValue("false");
}
} else {
listBox.setValue("false");
}
@ -63,15 +64,12 @@ public class BooleanFld extends AbstractFld {
HtmlLayoutContainer descr;
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");
} else {
// listBox.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");
}
horiz.add(listBox, new BoxLayoutData(new Margins()));

View File

@ -31,8 +31,8 @@ import com.sencha.gxt.widget.core.client.form.ComboBox;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ColumnFld extends AbstractFld implements
@ -47,7 +47,7 @@ public class ColumnFld extends AbstractFld implements
private SimpleContainer vContainer;
/**
* @param parameter
* @param parameter parameter
*/
public ColumnFld(Parameter parameter) {
super(parameter);

View File

@ -39,8 +39,8 @@ import com.sencha.gxt.widget.core.client.grid.Grid;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ColumnListFld extends AbstractFld implements
@ -61,7 +61,7 @@ public class ColumnListFld extends AbstractFld implements
/**
*
* @param parameter
* @param parameter parameter
*/
public ColumnListFld(Parameter parameter) {
super(parameter);

View File

@ -23,8 +23,8 @@ import com.sencha.gxt.widget.core.client.form.DateField;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class DateFld extends AbstractFld {
@ -34,7 +34,7 @@ public class DateFld extends AbstractFld {
private DateTimeFormat dateFormat;
/**
* @param parameter
* @param parameter parameter
*/
public DateFld(Parameter parameter) {
super(parameter);

View File

@ -16,21 +16,23 @@ import com.sencha.gxt.widget.core.client.form.DoubleField;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class DoubleFld extends AbstractFld {
private SimpleContainer fieldContainer;
private DoubleField numberField;
/**
* @param operator
*
* @param parameter
* parameter
*/
public DoubleFld(Parameter parameter) {
super(parameter);
fieldContainer=new SimpleContainer();
fieldContainer = new SimpleContainer();
HBoxLayoutContainer horiz = new HBoxLayoutContainer();
horiz.setPack(BoxLayoutPack.START);
horiz.setEnableOverflow(false);
@ -42,7 +44,7 @@ public class DoubleFld extends AbstractFld {
if (p.getDefaultValue() != null)
numberField.setValue(Double.parseDouble(p.getDefaultValue()));
numberField.setAllowBlank(false);
HtmlLayoutContainer descr;
if (p.getDescription() == null) {
@ -50,52 +52,40 @@ public class DoubleFld extends AbstractFld {
descr.addStyleName("workflow-fieldDescription");
} else {
//numberField.setToolTip(p.getDescription());
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>"
+ p.getDescription() + "</p>");
// numberField.setToolTip(p.getDescription());
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>" + p.getDescription() + "</p>");
descr.addStyleName("workflow-fieldDescription");
}
SimpleContainer vContainer=new SimpleContainer();
SimpleContainer vContainer = new SimpleContainer();
VerticalLayoutContainer vField = new VerticalLayoutContainer();
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer(
"Double Value");
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer("Double Value");
typeDescription.setStylePrimaryName("workflow-parameters-description");
vField.add(numberField, new VerticalLayoutData(-1,-1,new Margins(0)));
vField.add(typeDescription, 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)));
vContainer.add(vField);
horiz.add(vContainer, new BoxLayoutData(new Margins()));
horiz.add(descr, new BoxLayoutData(new Margins()));
fieldContainer.add(horiz);
fieldContainer.forceLayout();
}
/**
*
*/
@Override
public String getValue() {
return numberField.getCurrentValue().toString();
}
/**
*
*/
@Override
public Widget getWidget() {
return fieldContainer;
}
/**
*
*/
@Override
public boolean isValid() {
return numberField.isValid();
}
}

View File

@ -19,8 +19,8 @@ import com.sencha.gxt.widget.core.client.form.SimpleComboBox;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class EnumFld extends AbstractFld {
@ -30,6 +30,7 @@ public class EnumFld extends AbstractFld {
/**
* @param parameter
* parameter
*/
public EnumFld(Parameter parameter) {
super(parameter);
@ -57,9 +58,8 @@ public class EnumFld extends AbstractFld {
descr.addStyleName("workflow-fieldDescription");
} else {
//listBox.setToolTip(p.getDescription());
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>"
+ p.getDescription() + "</p>");
// listBox.setToolTip(p.getDescription());
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>" + p.getDescription() + "</p>");
descr.addStyleName("workflow-fieldDescription");
}
horiz.add(listBox, new BoxLayoutData(new Margins()));
@ -90,5 +90,5 @@ public class EnumFld extends AbstractFld {
public boolean isValid() {
return listBox.isValid();
}
}

View File

@ -40,8 +40,8 @@ import com.sencha.gxt.widget.core.client.form.TextField;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class FileFld extends AbstractFld {
@ -62,7 +62,7 @@ public class FileFld extends AbstractFld {
private TextButton downloadButton;
/**
* @param parameter
* @param parameter parameter
*/
public FileFld(Parameter parameter) {
super(parameter);

View File

@ -16,8 +16,8 @@ import com.sencha.gxt.widget.core.client.form.FloatField;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class FloatFld extends AbstractFld {
@ -26,7 +26,9 @@ public class FloatFld extends AbstractFld {
private FloatField numberField;
/**
* @param operator
*
* @param parameter
* parameter
*/
public FloatFld(Parameter parameter) {
super(parameter);
@ -50,20 +52,17 @@ public class FloatFld extends AbstractFld {
descr.addStyleName("workflow-fieldDescription");
} else {
//numberField.setToolTip(p.getDescription());
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>"
+ p.getDescription() + "</p>");
// numberField.setToolTip(p.getDescription());
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>" + p.getDescription() + "</p>");
descr.addStyleName("workflow-fieldDescription");
}
SimpleContainer vContainer = new SimpleContainer();
VerticalLayoutContainer vField = new VerticalLayoutContainer();
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer(
"Float Value");
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer("Float Value");
typeDescription.setStylePrimaryName("workflow-parameters-description");
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);
horiz.add(vContainer, new BoxLayoutData(new Margins()));
@ -74,18 +73,13 @@ public class FloatFld extends AbstractFld {
}
/**
*
*/
@Override
public String getValue() {
Float f = numberField.getCurrentValue();
return f.toString();
}
/**
*
*/
@Override
public Widget getWidget() {
return fieldContainer;

View File

@ -16,8 +16,8 @@ import com.sencha.gxt.widget.core.client.form.IntegerField;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class IntFld extends AbstractFld {
@ -26,7 +26,9 @@ public class IntFld extends AbstractFld {
private IntegerField numberField;
/**
* @param operator
*
* @param parameter
* parameter
*/
public IntFld(Parameter parameter) {
super(parameter);
@ -50,21 +52,19 @@ public class IntFld extends AbstractFld {
descr.addStyleName("workflow-fieldDescription");
} else {
//numberField.setToolTip(p.getDescription());
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>"
+ p.getDescription() + "</p>");
// numberField.setToolTip(p.getDescription());
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>" + p.getDescription() + "</p>");
descr.addStyleName("workflow-fieldDescription");
}
SimpleContainer vContainer=new SimpleContainer();
SimpleContainer vContainer = new SimpleContainer();
VerticalLayoutContainer vField = new VerticalLayoutContainer();
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer(
"Integer Value");
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer("Integer Value");
typeDescription.setStylePrimaryName("workflow-parameters-description");
vField.add(numberField, new VerticalLayoutData(-1,-1,new Margins(0)));
vField.add(typeDescription, 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)));
vContainer.add(vField);
horiz.add(vContainer, new BoxLayoutData(new Margins()));
horiz.add(descr, new BoxLayoutData(new Margins()));
@ -89,8 +89,7 @@ public class IntFld extends AbstractFld {
public Widget getWidget() {
return fieldContainer;
}
@Override
public boolean isValid() {
return numberField.isValid();

View File

@ -28,7 +28,7 @@ import com.sencha.gxt.widget.core.client.form.IntegerField;
/**
*
* @author Giancarlo Panichi
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
*
*
*/
public class ListIntFld extends AbstractFld {
@ -43,22 +43,23 @@ public class ListIntFld extends AbstractFld {
/**
* @param parameter
* parameter
*/
public ListIntFld(Parameter parameter) {
super(parameter);
this.listParameter = (ListParameter) parameter;
listContainer = new SimpleContainer();
vp = new VerticalLayoutContainer();
items = new ArrayList<Item>();
addField(null);
listContainer.add(vp, new MarginData(new Margins()));
fieldContainer = new SimpleContainer();
horiz = new HBoxLayoutContainer();
horiz.setPack(BoxLayoutPack.START);
horiz.setEnableOverflow(false);
HtmlLayoutContainer descr;
if (listParameter.getDescription() == null) {
@ -66,9 +67,9 @@ public class ListIntFld extends AbstractFld {
descr.addStyleName("workflow-fieldDescription");
} else {
//listContainer.setToolTip(listParameter.getDescription());
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>"
+ listParameter.getDescription() + "</p>");
// listContainer.setToolTip(listParameter.getDescription());
descr = new HtmlLayoutContainer(
"<p style='margin-left:5px !important;'>" + listParameter.getDescription() + "</p>");
descr.addStyleName("workflow-fieldDescription");
}
@ -77,14 +78,13 @@ public class ListIntFld extends AbstractFld {
fieldContainer.add(horiz);
fieldContainer.forceLayout();
}
private void addField(Item upperItem) {
ObjectParameter objPar = new ObjectParameter(listParameter.getName(),
listParameter.getDescription(), listParameter.getType(), null);
ObjectParameter objPar = new ObjectParameter(listParameter.getName(), listParameter.getDescription(),
listParameter.getType(), null);
if (upperItem == null) {
Item item = new Item(objPar, true);
@ -114,11 +114,11 @@ public class ListIntFld extends AbstractFld {
items.remove(item);
vp.remove(item);
if (items.size() == 1) {
items.get(0).hideCancelButton();
}
simpleContainer.forceLayout();
}
@ -172,10 +172,10 @@ public class ListIntFld extends AbstractFld {
*/
public Item(ObjectParameter objectParameter, boolean first) {
super();
field = new IntegerField();
field.setAllowBlank(false);
addBtn = new TextButton("");
addBtn.setIcon(DataMinerManager.resources.add());

View File

@ -22,8 +22,8 @@ import com.sencha.gxt.widget.core.client.container.VerticalLayoutContainer;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class ListStringFld extends AbstractFld {
@ -38,6 +38,7 @@ public class ListStringFld extends AbstractFld {
/**
*
* @param parameter
* parameter
*/
public ListStringFld(Parameter parameter) {
super(parameter);
@ -61,9 +62,9 @@ public class ListStringFld extends AbstractFld {
descr.addStyleName("workflow-fieldDescription");
} else {
/*listContainer.setToolTip(listParameter.getDescription());*/
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>"
+ listParameter.getDescription() + "</p>");
/* listContainer.setToolTip(listParameter.getDescription()); */
descr = new HtmlLayoutContainer(
"<p style='margin-left:5px !important;'>" + listParameter.getDescription() + "</p>");
descr.addStyleName("workflow-fieldDescription");
}
@ -76,8 +77,8 @@ public class ListStringFld extends AbstractFld {
protected void addField(StringItem upperItem) {
ObjectParameter objPar = new ObjectParameter(listParameter.getName(),
listParameter.getDescription(), listParameter.getType(), null);
ObjectParameter objPar = new ObjectParameter(listParameter.getName(), listParameter.getDescription(),
listParameter.getType(), null);
if (upperItem == null) {
StringItem item = new StringItem(this, objPar, true);
@ -91,30 +92,27 @@ public class ListStringFld extends AbstractFld {
upperItem.forceLayout();
StringItem item = new StringItem(this, objPar, false);
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 {
upperItem.forceLayout();
StringItem item = new StringItem(this, objPar, true);
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();
}
protected void forceLayout(){
protected void forceLayout() {
vp.forceLayout();
horiz.forceLayout();
fieldContainer.forceLayout();
}
/**
* @param item
*/
protected void removeField(StringItem item) {
items.remove(item);
@ -124,7 +122,7 @@ public class ListStringFld extends AbstractFld {
items.get(0).hideCancelButton();
items.get(0).forceLayout();
}
forceLayout();
}
@ -168,6 +166,4 @@ public class ListStringFld extends AbstractFld {
return valid;
}
}

View File

@ -12,8 +12,8 @@ import com.sencha.gxt.widget.core.client.form.FieldLabel;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class OperatorFieldWidget {
@ -23,46 +23,49 @@ public class OperatorFieldWidget {
private FieldLabel parameterLabel;
/**
*
* @param parameter
* parameter
*/
public OperatorFieldWidget(Parameter p) {
public OperatorFieldWidget(Parameter parameter) {
super();
this.parameter = p;
this.parameter = parameter;
try {
if (p.getTypology() != null) {
switch (p.getTypology()) {
if (parameter.getTypology() != null) {
switch (parameter.getTypology()) {
case COLUMN:
field = new ColumnFld(p);
field = new ColumnFld(parameter);
break;
case COLUMN_LIST:
field = new ColumnListFld(p);
field = new ColumnListFld(parameter);
break;
case ENUM:
field = new EnumFld(p);
field = new EnumFld(parameter);
break;
case FILE:
field = new FileFld(p);
field = new FileFld(parameter);
break;
case LIST:
field = createListField(p);
field = createListField(parameter);
break;
case OBJECT:
field = createObjectField(p);
field = createObjectField(parameter);
break;
case TABULAR:
field = new TabularFld(p);
field = new TabularFld(parameter);
break;
case TABULAR_LIST:
field = new TabularListFld(p);
field = new TabularListFld(parameter);
break;
case WKT:
field = new WKTFld(p);
field = new WKTFld(parameter);
break;
case DATE:
field = new DateFld(p);
break;
field = new DateFld(parameter);
break;
case TIME:
field = new TimeFld(p);
field = new TimeFld(parameter);
break;
default:
break;
@ -71,12 +74,12 @@ public class OperatorFieldWidget {
}
if (field == null) {
parameterLabel = new FieldLabel(null, p.getName());
parameterLabel = new FieldLabel(null, parameter.getName());
parameterLabel.setLabelWidth(200);
parameterLabel.setLabelWordWrap(true);
} else {
parameterLabel = new FieldLabel(field.getWidget(), p.getName());
parameterLabel = new FieldLabel(field.getWidget(), parameter.getName());
parameterLabel.setLabelWidth(200);
parameterLabel.setLabelWordWrap(true);
}
@ -107,11 +110,12 @@ public class OperatorFieldWidget {
}
/**
* @param p
* @return
* @param parameter
* parameter
* @return abstract field
*/
private AbstractFld createObjectField(Parameter p) {
ObjectParameter objectParameter = (ObjectParameter) p;
private AbstractFld createObjectField(Parameter parameter) {
ObjectParameter objectParameter = (ObjectParameter) parameter;
String type = objectParameter.getType();
if (type.contentEquals(Integer.class.getName())) {
return new IntFld(objectParameter);
@ -127,18 +131,15 @@ public class OperatorFieldWidget {
return null;
}
/**
*
*/
private AbstractFld createListField(Parameter p) {
ListParameter listParameter = (ListParameter) p;
String type = listParameter.getType();
if (type.contentEquals(String.class.getName())
|| type.contentEquals("STRING")) { // TODO REMOVE "STRING"
if (type.contentEquals(String.class.getName()) || type.contentEquals("STRING")) { // TODO
// REMOVE
// "STRING"
return new ListStringFld(listParameter);
} else if (type.contentEquals(Integer.class.getName())
|| type.contentEquals("NUMBER")) {
} else if (type.contentEquals(Integer.class.getName()) || type.contentEquals("NUMBER")) {
return new ListIntFld(listParameter);
}
// } else if (type.contentEquals(Boolean.class.getName())) {
@ -152,9 +153,6 @@ public class OperatorFieldWidget {
return null;
}
/**
*
*/
public void updateOperatorParameterValue() {
this.parameter.setValue(this.getFieldValue());
}

View File

@ -19,8 +19,8 @@ import com.sencha.gxt.widget.core.client.form.TextField;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class StringFld extends AbstractFld {
@ -29,7 +29,7 @@ public class StringFld extends AbstractFld {
private TextField textField;
/**
* @param parameter
* @param parameter parameter
*/
public StringFld(Parameter parameter) {
super(parameter);

View File

@ -12,7 +12,7 @@ import com.sencha.gxt.widget.core.client.form.TextField;
/**
*
* @author Giancarlo Panichi
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
*
*
*/
public class StringItem extends HBoxLayoutContainer {
@ -22,7 +22,10 @@ public class StringItem extends HBoxLayoutContainer {
private TextButton removeBtn;
/**
* @param objPar
*
* @param parent parend
* @param objectParameter object parameter
* @param first true if is first
*/
public StringItem(ListStringFld parent, ObjectParameter objectParameter, boolean first) {
super();

View File

@ -30,8 +30,8 @@ import com.sencha.gxt.widget.core.client.form.TextField;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class TabItem extends HBoxLayoutContainer {
@ -49,12 +49,14 @@ public class TabItem extends HBoxLayoutContainer {
/**
*
* @param tabularListFld
* @param parent
* parent
* @param tabularParameter
* tabular parameter
* @param first
* true if is first
*/
public TabItem(TabularListFld parent, TabularParameter tabularParameter,
boolean first) {
public TabItem(TabularListFld parent, TabularParameter tabularParameter, boolean first) {
super();
this.parent = parent;
initDialog();
@ -90,8 +92,7 @@ public class TabItem extends HBoxLayoutContainer {
}
});
selectButton2.setVisible(false);
downloadButton = new TextButton("");
downloadButton.setIcon(DataMinerManager.resources.download());
downloadButton.addSelectHandler(new SelectEvent.SelectHandler() {
@ -102,8 +103,7 @@ public class TabItem extends HBoxLayoutContainer {
}
});
downloadButton.setVisible(false);
addBtn = new TextButton("");
addBtn.setIcon(DataMinerManager.resources.add());
addBtn.addSelectHandler(new SelectEvent.SelectHandler() {
@ -128,20 +128,18 @@ public class TabItem extends HBoxLayoutContainer {
});
removeBtn.setVisible(!first);
setPack(BoxLayoutPack.START);
setEnableOverflow(false);
add(tableDescription, new BoxLayoutData(new Margins()));
add(selectButton, new BoxLayoutData(new Margins()));
add(selectButton2, new BoxLayoutData(new Margins()));
add(downloadButton, new BoxLayoutData(new Margins()));
add(addBtn, new BoxLayoutData(new Margins()));
add(removeBtn, new BoxLayoutData(new Margins()));
forceLayout();
}
private void initDialog() {
@ -158,7 +156,8 @@ public class TabItem extends HBoxLayoutContainer {
* "multipart/x-zip"
*/
// 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"
@ -190,8 +189,7 @@ public class TabItem extends HBoxLayoutContainer {
@Override
public void onFailed(Throwable throwable) {
Log.error("Error in create project: "
+ throwable.getLocalizedMessage());
Log.error("Error in create project: " + throwable.getLocalizedMessage());
UtilsGXT3.alert("Error", throwable.getLocalizedMessage());
throwable.printStackTrace();
}
@ -214,73 +212,63 @@ public class TabItem extends HBoxLayoutContainer {
private void retrieveTableInformation(Item item) {
Log.debug("Retrieved: " + item);
itemDescriptionSelected = new ItemDescription(
item.getId(), item.getName(), item.getOwner(), item.getPath(),
itemDescriptionSelected = new ItemDescription(item.getId(), item.getName(), item.getOwner(), item.getPath(),
item.getType().name());
DataMinerPortletServiceAsync.INSTANCE.retrieveTableInformation(item,
new AsyncCallback<TableItemSimple>() {
DataMinerPortletServiceAsync.INSTANCE.retrieveTableInformation(item, new AsyncCallback<TableItemSimple>() {
@Override
public void onFailure(Throwable caught) {
Log.error("Error in retrieveTableInformation "
+ caught.getMessage());
if (caught instanceof SessionExpiredServiceException) {
UtilsGXT3.alert("Error", "Expired Session");
@Override
public void onFailure(Throwable caught) {
Log.error("Error in retrieveTableInformation " + caught.getMessage());
if (caught instanceof SessionExpiredServiceException) {
UtilsGXT3.alert("Error", "Expired Session");
} else {
UtilsGXT3.alert("Error",
"Error retrieving table information: "
+ caught.getLocalizedMessage());
}
} else {
UtilsGXT3.alert("Error", "Error retrieving table information: " + caught.getLocalizedMessage());
}
}
}
@Override
public void onSuccess(TableItemSimple result) {
Log.debug("Retrieved: " + result);
selectedTableItem = result;
showFieldWithSelection();
@Override
public void onSuccess(TableItemSimple result) {
Log.debug("Retrieved: " + result);
selectedTableItem = result;
showFieldWithSelection();
}
});
}
});
}
private void downloadFile() {
if (itemDescriptionSelected != null) {
DataMinerPortletServiceAsync.INSTANCE.getPublicLink(
itemDescriptionSelected, new AsyncCallback<String>() {
DataMinerPortletServiceAsync.INSTANCE.getPublicLink(itemDescriptionSelected, new AsyncCallback<String>() {
@Override
public void onFailure(Throwable caught) {
if (caught instanceof SessionExpiredServiceException) {
EventBusProvider.INSTANCE
.fireEvent(new SessionExpiredEvent());
} else {
Log.error("Error downloading table: "
+ caught.getLocalizedMessage());
UtilsGXT3.alert("Error",
caught.getLocalizedMessage());
}
caught.printStackTrace();
@Override
public void onFailure(Throwable caught) {
if (caught instanceof SessionExpiredServiceException) {
EventBusProvider.INSTANCE.fireEvent(new SessionExpiredEvent());
} else {
Log.error("Error downloading table: " + caught.getLocalizedMessage());
UtilsGXT3.alert("Error", caught.getLocalizedMessage());
}
caught.printStackTrace();
}
}
@Override
public void onSuccess(String link) {
Log.debug("Retrieved link: " + link);
Window.open(link, itemDescriptionSelected.getName(), "");
}
@Override
public void onSuccess(String link) {
Log.debug("Retrieved link: " + link);
Window.open(link, itemDescriptionSelected.getName(), "");
}
});
});
} else {
UtilsGXT3.info("Attention", "Select a Table!");
}
}
/**
*
*/

View File

@ -47,28 +47,26 @@ import com.sencha.gxt.widget.core.client.form.TextField;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class TabularFld extends AbstractFld implements
HasTabularFldChangeEventHandler {
public class TabularFld extends AbstractFld implements HasTabularFldChangeEventHandler {
private SimpleContainer fieldContainer;
private HBoxLayoutContainer horiz;
private VerticalLayoutContainer vp;
private WorkspaceExplorerSelectDialog wselectDialog;
private TextButton selectButton, selectButton2, cancelButton,
downloadButton;
private TextButton selectButton, selectButton2, cancelButton, downloadButton;
private HtmlLayoutContainer templatesList;
private TableItemSimple selectedTableItem = null;
private ItemDescription itemDescriptionSelected;
private TabularParameter tabularParameter;
/**
* @param parameter
* parameter
*/
public TabularFld(Parameter parameter) {
super(parameter);
@ -85,8 +83,7 @@ public class TabularFld extends AbstractFld implements
showNoSelectionField();
} catch (Throwable e) {
Log.error("TabularField: " + e.getLocalizedMessage());
UtilsGXT3.alert("Error",
"Error creating Tabular Field: " + e.getLocalizedMessage());
UtilsGXT3.alert("Error", "Error creating Tabular Field: " + e.getLocalizedMessage());
e.printStackTrace();
}
}
@ -104,8 +101,7 @@ public class TabularFld extends AbstractFld implements
first = false;
}
templatesList = new HtmlLayoutContainer(
"<p>Suitable Data Set Templates: <br>" + list + "</p>");
templatesList = new HtmlLayoutContainer("<p>Suitable Data Set Templates: <br>" + list + "</p>");
templatesList.addStyleName("workflow-parameters-description");
}
@ -123,8 +119,8 @@ public class TabularFld extends AbstractFld implements
descr.addStyleName("workflow-fieldDescription");
} else {
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>"
+ tabularParameter.getDescription() + "</p>");
descr = new HtmlLayoutContainer(
"<p style='margin-left:5px !important;'>" + tabularParameter.getDescription() + "</p>");
descr.addStyleName("workflow-fieldDescription");
}
@ -149,7 +145,8 @@ public class TabularFld extends AbstractFld implements
* "multipart/x-zip"
*/
// 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"
@ -162,8 +159,7 @@ public class TabularFld extends AbstractFld implements
* FilterCriteria(allowedMimeTypes, allowedFileExtensions, new
* HashMap<String, String>());
*/
wselectDialog = new WorkspaceExplorerSelectDialog("Select CSV",
false);
wselectDialog = new WorkspaceExplorerSelectDialog("Select CSV", false);
// filterCriteria, selectableTypes);
WorskpaceExplorerSelectNotificationListener handler = new WorskpaceExplorerSelectNotificationListener() {
@ -183,10 +179,8 @@ public class TabularFld extends AbstractFld implements
@Override
public void onFailed(Throwable throwable) {
Log.error("Error in create project: "
+ throwable.getLocalizedMessage());
UtilsGXT3.alert("Error",
throwable.getLocalizedMessage());
Log.error("Error in create project: " + throwable.getLocalizedMessage());
UtilsGXT3.alert("Error", throwable.getLocalizedMessage());
throwable.printStackTrace();
}
@ -201,17 +195,14 @@ public class TabularFld extends AbstractFld implements
}
};
wselectDialog
.addWorkspaceExplorerSelectNotificationListener(handler);
wselectDialog.addWorkspaceExplorerSelectNotificationListener(handler);
wselectDialog.setZIndex(XDOM.getTopZIndex());
} catch (Throwable e) {
Log.error("TabularField error using WorkspaceExplorerSelectDialog: "
+ e.getLocalizedMessage());
Log.error("TabularField error using WorkspaceExplorerSelectDialog: " + e.getLocalizedMessage());
e.printStackTrace();
throw new Exception(
"TabularField error using WorkspaceExplorerSelectDialog: "
+ e.getLocalizedMessage());
"TabularField error using WorkspaceExplorerSelectDialog: " + e.getLocalizedMessage());
}
selectButton = new TextButton("Select Data Set");
@ -268,66 +259,56 @@ public class TabularFld extends AbstractFld implements
private void retrieveTableInformation(Item item) {
Log.debug("Retrieved: " + item);
itemDescriptionSelected = new ItemDescription(
item.getId(), item.getName(), item.getOwner(), item.getPath(),
itemDescriptionSelected = new ItemDescription(item.getId(), item.getName(), item.getOwner(), item.getPath(),
item.getType().name());
DataMinerPortletServiceAsync.INSTANCE.retrieveTableInformation(item,
new AsyncCallback<TableItemSimple>() {
DataMinerPortletServiceAsync.INSTANCE.retrieveTableInformation(item, new AsyncCallback<TableItemSimple>() {
@Override
public void onFailure(Throwable caught) {
Log.error("Error in retrieveTableInformation "
+ caught.getMessage());
if (caught instanceof SessionExpiredServiceException) {
UtilsGXT3.alert("Error", "Expired Session");
@Override
public void onFailure(Throwable caught) {
Log.error("Error in retrieveTableInformation " + caught.getMessage());
if (caught instanceof SessionExpiredServiceException) {
UtilsGXT3.alert("Error", "Expired Session");
} else {
UtilsGXT3.alert("Error",
"Error retrieving table information: "
+ caught.getLocalizedMessage());
}
} else {
UtilsGXT3.alert("Error", "Error retrieving table information: " + caught.getLocalizedMessage());
}
}
}
@Override
public void onSuccess(TableItemSimple result) {
Log.debug("Retrieved: " + result);
selectedTableItem = result;
showFieldWithSelection();
updateListeners(selectedTableItem);
}
});
@Override
public void onSuccess(TableItemSimple result) {
Log.debug("Retrieved: " + result);
selectedTableItem = result;
showFieldWithSelection();
updateListeners(selectedTableItem);
}
});
}
private void downloadFile() {
if (itemDescriptionSelected != null) {
DataMinerPortletServiceAsync.INSTANCE.getPublicLink(
itemDescriptionSelected, new AsyncCallback<String>() {
DataMinerPortletServiceAsync.INSTANCE.getPublicLink(itemDescriptionSelected, new AsyncCallback<String>() {
@Override
public void onFailure(Throwable caught) {
if (caught instanceof SessionExpiredServiceException) {
EventBusProvider.INSTANCE
.fireEvent(new SessionExpiredEvent());
} else {
Log.error("Error downloading table: "
+ caught.getLocalizedMessage());
UtilsGXT3.alert("Error",
caught.getLocalizedMessage());
}
caught.printStackTrace();
@Override
public void onFailure(Throwable caught) {
if (caught instanceof SessionExpiredServiceException) {
EventBusProvider.INSTANCE.fireEvent(new SessionExpiredEvent());
} else {
Log.error("Error downloading table: " + caught.getLocalizedMessage());
UtilsGXT3.alert("Error", caught.getLocalizedMessage());
}
caught.printStackTrace();
}
}
@Override
public void onSuccess(String link) {
Log.debug("Retrieved link: " + link);
Window.open(link, itemDescriptionSelected.getName(), "");
}
@Override
public void onSuccess(String link) {
Log.debug("Retrieved link: " + link);
Window.open(link, itemDescriptionSelected.getName(), "");
}
});
});
} else {
UtilsGXT3.info("Attention", "Select a Table!");
@ -397,10 +378,8 @@ public class TabularFld extends AbstractFld implements
}
@Override
public HandlerRegistration addTabularFldChangeEventHandler(
TabularFldChangeEventHandler handler) {
return fieldContainer.addHandler(handler,
TabularFldChangeEvent.getType());
public HandlerRegistration addTabularFldChangeEventHandler(TabularFldChangeEventHandler handler) {
return fieldContainer.addHandler(handler, TabularFldChangeEvent.getType());
}

View File

@ -22,8 +22,8 @@ import com.sencha.gxt.widget.core.client.container.VerticalLayoutContainer;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class TabularListFld extends AbstractFld {
@ -37,6 +37,7 @@ public class TabularListFld extends AbstractFld {
/**
* @param parameter
* parameter
*/
public TabularListFld(Parameter parameter) {
super(parameter);
@ -81,8 +82,8 @@ public class TabularListFld extends AbstractFld {
descr.addStyleName("workflow-fieldDescription");
} else {
/* listContainer.setToolTip(listParameter.getDescription()); */
descr = new HtmlLayoutContainer("<p style='margin-left:5px !important;'>"
+ tabularListParameter.getDescription() + "</p>");
descr = new HtmlLayoutContainer(
"<p style='margin-left:5px !important;'>" + tabularListParameter.getDescription() + "</p>");
descr.addStyleName("workflow-fieldDescription");
}
@ -97,12 +98,9 @@ public class TabularListFld extends AbstractFld {
protected void addField(TabItem upperItem) {
try {
TabularParameter tabPar = new TabularParameter(
tabularListParameter.getName(),
tabularListParameter.getDescription(), null,
tabularListParameter.getTemplates(),
tabularListParameter.getDefaultMimeType(),
tabularListParameter.getSupportedMimeTypes());
TabularParameter tabPar = new TabularParameter(tabularListParameter.getName(),
tabularListParameter.getDescription(), null, tabularListParameter.getTemplates(),
tabularListParameter.getDefaultMimeType(), tabularListParameter.getSupportedMimeTypes());
if (upperItem == null) {
TabItem item = new TabItem(this, tabPar, true);
@ -137,10 +135,6 @@ public class TabularListFld extends AbstractFld {
}
}
/**
*
* @param item
*/
protected void removeField(TabItem item) {
items.remove(item);
@ -152,9 +146,6 @@ public class TabularListFld extends AbstractFld {
forceLayout();
}
/**
*
*/
protected void forceLayout() {
vp.forceLayout();
listContainer.forceLayout();
@ -162,9 +153,6 @@ public class TabularListFld extends AbstractFld {
fieldContainer.forceLayout();
}
/**
*
*/
@Override
public String getValue() {
String separator = tabularListParameter.getSeparator();

View File

@ -24,8 +24,8 @@ import com.sencha.gxt.widget.core.client.form.TimeField;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class TimeFld extends AbstractFld {
@ -36,6 +36,7 @@ public class TimeFld extends AbstractFld {
/**
* @param parameter
* parameter
*/
public TimeFld(Parameter parameter) {
super(parameter);
@ -60,26 +61,21 @@ public class TimeFld extends AbstractFld {
HtmlLayoutContainer descr;
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");
} else {
// 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");
}
SimpleContainer vContainer = new SimpleContainer();
VerticalLayoutContainer vField = new VerticalLayoutContainer();
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer(
"Time Value");
HtmlLayoutContainer typeDescription = new HtmlLayoutContainer("Time Value");
typeDescription.setStylePrimaryName("workflow-parameters-description");
vField.add(timeField, 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);
fieldContainer = new SimpleContainer();

View File

@ -30,8 +30,8 @@ import com.sencha.gxt.widget.core.client.form.TextField;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class WKTFld extends AbstractFld {
@ -53,6 +53,7 @@ public class WKTFld extends AbstractFld {
/**
* @param parameter
* parameter
*/
public WKTFld(Parameter parameter) {
super(parameter);
@ -71,14 +72,12 @@ public class WKTFld extends AbstractFld {
HtmlLayoutContainer descr;
if (wktParameter.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");
} else {
descr = new HtmlLayoutContainer(
"<p style='margin-left:5px !important;'>"
+ wktParameter.getDescription() + "</p>");
"<p style='margin-left:5px !important;'>" + wktParameter.getDescription() + "</p>");
descr.addStyleName("workflow-fieldDescription");
}
@ -136,8 +135,7 @@ public class WKTFld extends AbstractFld {
showFieldWithSelection();
break;
case Failed:
Log.error("Error during area selection: "
+ event.getException());
Log.error("Error during area selection: " + event.getException());
UtilsGXT3.alert("Error", event.getErrorMessage());
break;
default:
@ -155,8 +153,7 @@ public class WKTFld extends AbstractFld {
}
private void init() {
selectButton = new TextButton("Draw a "
+ wktParameter.getWktGeometryType().getLabel());
selectButton = new TextButton("Draw a " + wktParameter.getWktGeometryType().getLabel());
selectButton.setIcon(DataMinerManager.resources.drawGeometry());
selectButton.addSelectHandler(new SelectEvent.SelectHandler() {
@ -166,8 +163,8 @@ public class WKTFld extends AbstractFld {
}
});
//selectButton.setToolTip("Draw a "
// + wktParameter.getWktGeometryType().getLabel());
// selectButton.setToolTip("Draw a "
// + wktParameter.getWktGeometryType().getLabel());
selectButton2 = new TextButton("");
selectButton2.setIcon(DataMinerManager.resources.folderExplore());
@ -178,8 +175,8 @@ public class WKTFld extends AbstractFld {
drawAGeometry();
}
});
//selectButton2.setToolTip("Select Another "
// + wktParameter.getWktGeometryType().getLabel());
// selectButton2.setToolTip("Select Another "
// + wktParameter.getWktGeometryType().getLabel());
cancelButton = new TextButton("");
cancelButton.setIcon(DataMinerManager.resources.cancel());

View File

@ -11,7 +11,7 @@ import com.sencha.gxt.data.shared.PropertyAccess;
/**
*
* @author Giancarlo Panichi
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
*
*
*/
public interface ColumnItemProperties extends PropertyAccess<ColumnItem> {

View File

@ -10,7 +10,7 @@ import com.sencha.gxt.data.shared.PropertyAccess;
/**
*
* @author Giancarlo Panichi
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
*
*
*/
public interface ColumnItemPropertiesCombo extends PropertyAccess<ColumnItem> {

View File

@ -6,8 +6,8 @@ import com.google.gwt.resources.client.ImageResource;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public interface Resources extends ClientBundle {

View File

@ -20,8 +20,8 @@ import com.google.gwt.user.client.rpc.AsyncCallback;
/**
*
* @author Giancarlo Panichi email: <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public interface DataMinerPortletServiceAsync {

View File

@ -2,8 +2,8 @@ package org.gcube.portlets.user.dataminermanager.client.type;
/**
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public enum DataMinerWorkAreaElementType {

View File

@ -2,8 +2,8 @@ package org.gcube.portlets.user.dataminermanager.client.type;
/**
*
* @author "Giancarlo Panichi"
* <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public enum DataMinerWorkAreaEventType {

View File

@ -2,8 +2,8 @@ package org.gcube.portlets.user.dataminermanager.client.type;
/**
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public enum DataMinerWorkAreaRegionType {

View File

@ -3,7 +3,7 @@ package org.gcube.portlets.user.dataminermanager.client.type;
/**
*
* @author Giancarlo Panichi
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
*
*
*/
public enum DataMinerWorkAreaRequestEventType {

View File

@ -3,7 +3,7 @@ package org.gcube.portlets.user.dataminermanager.client.type;
/**
*
* @author Giancarlo Panichi
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
*
*
*/
public enum MenuType {

View File

@ -3,7 +3,7 @@ package org.gcube.portlets.user.dataminermanager.client.type;
/**
*
* @author Giancarlo Panichi
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
*
*
*/
public enum OperatorsClassificationRequestType {

View File

@ -2,8 +2,8 @@ package org.gcube.portlets.user.dataminermanager.client.type;
/**
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public enum OutputResourceRequestEventType {

View File

@ -2,8 +2,8 @@ package org.gcube.portlets.user.dataminermanager.client.type;
/**
*
* @author "Giancarlo Panichi"
* <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public enum SessionExpiredEventType {

View File

@ -2,8 +2,8 @@ package org.gcube.portlets.user.dataminermanager.client.type;
/**
*
* @author "Giancarlo Panichi"
* <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public enum UIStateEventType {

View File

@ -3,7 +3,7 @@ package org.gcube.portlets.user.dataminermanager.client.type;
/**
*
* @author Giancarlo Panichi
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
*
*
*/
public enum WPSMenuType {

View File

@ -4,8 +4,8 @@ import com.sencha.gxt.widget.core.client.box.MessageBox;
/**
*
* @author "Giancarlo Panichi"
* <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class InfoMessageBox extends MessageBox {

View File

@ -10,8 +10,8 @@ import com.sencha.gxt.widget.core.client.event.HideEvent.HideHandler;
/**
*
* @author "Giancarlo Panichi" <a
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
* @author Giancarlo Panichi
*
*
*/
public class UtilsGXT3 {

View File

@ -16,27 +16,29 @@ import com.sencha.gxt.widget.core.client.event.SelectEvent;
/**
*
* @author Giancarlo Panichi
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
*
*
*/
public class FileViewer extends SimpleContainer {
private FileResource fileResource;
/**
* @param mapImages
*
* @param computationId
* computation id
* @param fileResource
* file resource
*/
public FileViewer(ComputationId computationId,
FileResource fileResource) {
public FileViewer(ComputationId computationId, FileResource fileResource) {
super();
this.fileResource = fileResource;
//this.computationId = computationId;
// this.computationId = computationId;
init();
create();
}
private void init(){
private void init() {
setHeight(56);
}
@ -44,10 +46,8 @@ public class FileViewer extends SimpleContainer {
VerticalLayoutContainer lc = new VerticalLayoutContainer();
final String fileName = fileResource.getName();
final String fileUrl = fileResource.getUrl();
HtmlLayoutContainer fileNameHtml = new HtmlLayoutContainer(
"<div class='computation-output-fileName'><p>"
+ new SafeHtmlBuilder().appendEscaped(fileName)
.toSafeHtml().asString() + "</p></div>");
HtmlLayoutContainer fileNameHtml = new HtmlLayoutContainer("<div class='computation-output-fileName'><p>"
+ new SafeHtmlBuilder().appendEscaped(fileName).toSafeHtml().asString() + "</p></div>");
lc.add(fileNameHtml, new VerticalLayoutData(-1, -1, new Margins(0)));
TextButton downloadBtn = new TextButton("Download File");
downloadBtn.setIcon(DataMinerManager.resources.download());
@ -62,6 +62,5 @@ public class FileViewer extends SimpleContainer {
lc.add(downloadBtn, new VerticalLayoutData(-1, -1, new Margins(0)));
add(lc);
}
}

View File

@ -9,11 +9,10 @@ import java.util.Map.Entry;
import com.sencha.gxt.widget.core.client.container.HtmlLayoutContainer;
import com.sencha.gxt.widget.core.client.container.SimpleContainer;
/**
*
* @author Giancarlo Panichi
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
*
*
*/
public class HashMapViewer extends SimpleContainer {
@ -23,37 +22,31 @@ public class HashMapViewer extends SimpleContainer {
/**
*
* @param map
* map
*/
public HashMapViewer(Map<String, String> map) {
super();
this.map=map;
this.map = map;
init();
}
/**
*
*/
private void init() {
String html ="";
html += "<table class='jobViewer-table'>" +
" <colgroup>" +
" <col>" +
" <col class='jobViewer-table-oce-first'>" +
" </colgroup>"+
" <tbody>";
for (Entry<String, String> entry: map.entrySet())
if (entry.getKey()!=null) {
html += " <tr>" +
" <td>"+entry.getKey()+"</td>" +
" <td>"+entry.getValue()+"</td>" +
" </tr>";
String html = "";
html += "<table class='jobViewer-table'>" + " <colgroup>" + " <col>"
+ " <col class='jobViewer-table-oce-first'>" + " </colgroup>" + " <tbody>";
for (Entry<String, String> entry : map.entrySet())
if (entry.getKey() != null) {
html += " <tr>" + " <td>" + entry.getKey() + "</td>" + " <td>" + entry.getValue()
+ "</td>" + " </tr>";
}
html += " </tbody>" +
"</table>";
HtmlLayoutContainer htmlContainer=new HtmlLayoutContainer(html);
html += " </tbody>" + "</table>";
HtmlLayoutContainer htmlContainer = new HtmlLayoutContainer(html);
add(htmlContainer);
forceLayout();
}

Some files were not shown because too many files have changed in this diff Show More