diff --git a/ToolBoxTest-dev.launch b/ToolBoxTest-dev.launch new file mode 100644 index 0000000..4134a86 --- /dev/null +++ b/ToolBoxTest-dev.launch @@ -0,0 +1,22 @@ + + + + + + + + + + + + + + + + + + + + + + diff --git a/ToolBoxTest-prod.launch b/ToolBoxTest-prod.launch new file mode 100644 index 0000000..2b7418e --- /dev/null +++ b/ToolBoxTest-prod.launch @@ -0,0 +1,22 @@ + + + + + + + + + + + + + + + + + + + + + + diff --git a/pom.xml b/pom.xml new file mode 100644 index 0000000..7dcfa5d --- /dev/null +++ b/pom.xml @@ -0,0 +1,282 @@ + + + + + maven-parent + org.gcube.tools + 1.0.0 + + + + + + 4.0.0 + org.gcube.portlets.user + tabular-data-toolbox-widget + 1.0.0-SNAPSHOT + + tabular-data-toolbox-widget + tabular-data-toolbox-widget implements a tab panel to show property, tasks and so on + + + https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/tabular-data-toolbox-widget + + + + + Giancarlo Panichi + g.panichi@isti.cnr.it + CNR Pisa, Istituto di Scienza e Tecnologie dell'Informazione "A. Faedo" + + architect + developer + + + + + + + ${project.basedir}/distro + ${project.build.directory}/${project.build.finalName} + 2013-10-18 + templates + distro + config + + + 2.5.1 + + ${env.GLOBUS_LOCATION} + + UTF-8 + UTF-8 + + + + + localRun + + + org.slf4j + slf4j-api + compile + + + ch.qos.logback + logback-classic + 1.0.1 + runtime + + + + + + + + com.google.gwt + gwt-servlet + + + com.google.gwt + gwt-user + + + + javax.validation + validation-api + 1.0.0.GA + test + + + javax.validation + validation-api + 1.0.0.GA + sources + test + + + + com.sencha.gxt + gxt + 3.0.1 + + + + + + com.allen-sauer.gwt.log + gwt-log + + + + org.slf4j + slf4j-api + + + + + + junit + junit + 4.8.1 + test + + + + + + + + + + ${webappDirectory}/WEB-INF/classes + + + + org.apache.maven.plugins + maven-surefire-plugin + 2.16 + + true + **/GwtTest*.java + + + + + + org.apache.maven.surefire + surefire-junit47 + 2.16 + + + + + + + org.codehaus.mojo + gwt-maven-plugin + ${gwtVersion} + + + + + resources + + + + + ToolBox.html + ${webappDirectory} + org.gcube.portlets.user.td.toolboxwidget.ToolBox + **/GwtTest*.java + + + + + + maven-resources-plugin + 2.6 + + + copy-profile + process-resources + + copy-resources + + + ${configDirectory} + + + ${templatesDirectory} + + profile.xml + + true + + + + + + copy-distro-resources + process-resources + + copy-resources + + + ${distroDirectory} + + + ${templatesDirectory} + + profile.xml + descriptor.xml + + true + + + + + + + + maven-clean-plugin + 2.5 + + + + ${distroDirectory} + + ** + + false + + + ${configDirectory} + + ** + + false + + + + + + org.apache.maven.plugins + maven-assembly-plugin + 2.2 + + + ${templatesDirectory}/descriptor.xml + + + + + servicearchive + package + + single + + + + + + + + + + + + + org.gcube.distribution + maven-portal-bom + LATEST + pom + import + + + + + diff --git a/src/main/java/org/gcube/portlets/user/td/toolboxwidget/client/ToolBox.java b/src/main/java/org/gcube/portlets/user/td/toolboxwidget/client/ToolBox.java new file mode 100644 index 0000000..bfb0b66 --- /dev/null +++ b/src/main/java/org/gcube/portlets/user/td/toolboxwidget/client/ToolBox.java @@ -0,0 +1,16 @@ +package org.gcube.portlets.user.td.toolboxwidget.client; + +import com.google.web.bindery.event.shared.EventBus; +import com.sencha.gxt.widget.core.client.FramedPanel; + +public class ToolBox extends FramedPanel { + + public ToolBox(String name, EventBus eventBus) { + super(); + setId(name); + + + } + + +} diff --git a/src/main/java/org/gcube/portlets/user/td/toolboxwidget/client/ToolBoxEntry.java b/src/main/java/org/gcube/portlets/user/td/toolboxwidget/client/ToolBoxEntry.java new file mode 100644 index 0000000..b600bd5 --- /dev/null +++ b/src/main/java/org/gcube/portlets/user/td/toolboxwidget/client/ToolBoxEntry.java @@ -0,0 +1,25 @@ +package org.gcube.portlets.user.td.toolboxwidget.client; + +import com.allen_sauer.gwt.log.client.Log; +import com.google.gwt.core.client.EntryPoint; +import com.google.gwt.user.client.ui.RootPanel; +import com.google.web.bindery.event.shared.EventBus; +import com.google.web.bindery.event.shared.SimpleEventBus; + + +public class ToolBoxEntry implements EntryPoint { + + @Override + public void onModuleLoad() { + + EventBus eventBus = new SimpleEventBus(); + + ToolBox trProperties = new ToolBox( + "TRProperties", eventBus); + + trProperties.setHeadingText("Tabular Resource Properties"); + RootPanel.get().add(trProperties); + Log.info("" + trProperties); + + } +} diff --git a/src/main/resources/org/gcube/portlets/user/td/toolboxwidget/ToolBox.gwt.xml b/src/main/resources/org/gcube/portlets/user/td/toolboxwidget/ToolBox.gwt.xml new file mode 100644 index 0000000..e7f2437 --- /dev/null +++ b/src/main/resources/org/gcube/portlets/user/td/toolboxwidget/ToolBox.gwt.xml @@ -0,0 +1,28 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/main/resources/org/gcube/portlets/user/td/toolboxwidget/client/Messages.properties b/src/main/resources/org/gcube/portlets/user/td/toolboxwidget/client/Messages.properties new file mode 100644 index 0000000..c222555 --- /dev/null +++ b/src/main/resources/org/gcube/portlets/user/td/toolboxwidget/client/Messages.properties @@ -0,0 +1,2 @@ +sendButton = Send +nameField = Enter your name \ No newline at end of file diff --git a/src/main/resources/org/gcube/portlets/user/td/toolboxwidget/client/Messages_fr.properties b/src/main/resources/org/gcube/portlets/user/td/toolboxwidget/client/Messages_fr.properties new file mode 100644 index 0000000..b4a7627 --- /dev/null +++ b/src/main/resources/org/gcube/portlets/user/td/toolboxwidget/client/Messages_fr.properties @@ -0,0 +1,2 @@ +sendButton = Envoyer +nameField = Entrez votre nom \ No newline at end of file diff --git a/src/main/webapp/ToolBox.css b/src/main/webapp/ToolBox.css new file mode 100644 index 0000000..7aca7ac --- /dev/null +++ b/src/main/webapp/ToolBox.css @@ -0,0 +1,34 @@ +/** Add css rules here for your application. */ + + +/** Example rules used by the template application (remove for your app) */ +h1 { + font-size: 2em; + font-weight: bold; + color: #777777; + margin: 40px 0px 70px; + text-align: center; +} + +.sendButton { + display: block; + font-size: 16pt; +} + +/** Most GWT widgets already have a style name defined */ +.gwt-DialogBox { + width: 400px; +} + +.dialogVPanel { + margin: 5px; +} + +.serverResponseLabelError { + color: red; +} + +/** Set ids using widget.getElement().setId("idOfElement") */ +#closeButton { + margin: 15px 6px 6px; +} diff --git a/src/main/webapp/ToolBox.html b/src/main/webapp/ToolBox.html new file mode 100644 index 0000000..abcff1f --- /dev/null +++ b/src/main/webapp/ToolBox.html @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + + + Web Application Starter Project + + + + + + + + + + + + + + + + + + + + + + +

Web Application Starter Project

+ + + + + + + + + + + + +
Please enter your name:
+ + diff --git a/src/main/webapp/WEB-INF/web.xml b/src/main/webapp/WEB-INF/web.xml new file mode 100644 index 0000000..8f22976 --- /dev/null +++ b/src/main/webapp/WEB-INF/web.xml @@ -0,0 +1,27 @@ + + + + + + + + + jUnitHostImpl + com.google.gwt.junit.server.JUnitHostImpl + + + + + jUnitHostImpl + TDToolBoxManagerWidgets/junithost/* + + + + + + ToolBox.html + + + diff --git a/src/test/java/org/gcube/portlets/user/td/toolboxwidget/client/GwtTestToolBox.java b/src/test/java/org/gcube/portlets/user/td/toolboxwidget/client/GwtTestToolBox.java new file mode 100644 index 0000000..503dc59 --- /dev/null +++ b/src/test/java/org/gcube/portlets/user/td/toolboxwidget/client/GwtTestToolBox.java @@ -0,0 +1,60 @@ +package org.gcube.portlets.user.td.toolboxwidget.client; + + +import com.google.gwt.junit.client.GWTTestCase; + +/** + * GWT JUnit integration tests must extend GWTTestCase. + * Using "GwtTest*" naming pattern exclude them from running with + * surefire during the test phase. + * + * If you run the tests using the Maven command line, you will have to + * navigate with your browser to a specific url given by Maven. + * See http://mojo.codehaus.org/gwt-maven-plugin/user-guide/testing.html + * for details. + */ +public class GwtTestToolBox extends GWTTestCase { + + /** + * Must refer to a valid module that sources this class. + */ + public String getModuleName() { + return "org.gcube.portlets.user.td.toolboxwidget.ToolBoxJUnit"; + } + + + /** + * This test will send a request to the server + */ + public void testToolBox() { + // Create the service that we will test. + /*TDGWTServiceAsync tdGWTService = TDGWTServiceAsync.INSTANCE; + ServiceDefTarget target = (ServiceDefTarget) tdGWTService; + System.out.println(GWT.getModuleBaseURL() + "TDGWTService"); + target.setServiceEntryPoint(GWT.getModuleBaseURL() + "TDGWTService"); + + // Send a request to the server. + /*tdGWTService.getTabResourceInformation(new AsyncCallback(){ + + @Override + public void onFailure(Throwable caught) { + fail("Request failure: " + caught.getMessage()); + + } + + @Override + public void onSuccess(TabResource result) { + assertTrue(result!=null); + System.out.println(result); + finishTest(); + } + + });*/ + delayTestFinish(1000); + finishTest(); + + } + + + +} diff --git a/src/test/resources/org/gcube/portlets/user/td/toolboxwidget/ToolBoxJUnit.gwt.xml b/src/test/resources/org/gcube/portlets/user/td/toolboxwidget/ToolBoxJUnit.gwt.xml new file mode 100644 index 0000000..d6fe04f --- /dev/null +++ b/src/test/resources/org/gcube/portlets/user/td/toolboxwidget/ToolBoxJUnit.gwt.xml @@ -0,0 +1,14 @@ + + + + + + + + + + + + + diff --git a/templates/INSTALL b/templates/INSTALL new file mode 100644 index 0000000..e69de29 diff --git a/templates/LICENSE b/templates/LICENSE new file mode 100644 index 0000000..cc51139 --- /dev/null +++ b/templates/LICENSE @@ -0,0 +1,6 @@ +gCube System - License +------------------------------------------------------------ + +The gCube/gCore software is licensed as Free Open Source software conveying to the EUPL (http://ec.europa.eu/idabc/eupl). +The software and documentation is provided by its authors/distributors "as is" and no expressed or +implied warranty is given for its use, quality or fitness for a particular case. \ No newline at end of file diff --git a/templates/MAINTAINERS b/templates/MAINTAINERS new file mode 100644 index 0000000..0bc9be3 --- /dev/null +++ b/templates/MAINTAINERS @@ -0,0 +1 @@ +Giancarlo Panichi (giancarlo.panichi@isti.cnr.it), CNR Pisa, Istituto di Scienza e Tecnologie dell'Informazione "A. Faedo" diff --git a/templates/README b/templates/README new file mode 100644 index 0000000..e81341a --- /dev/null +++ b/templates/README @@ -0,0 +1,40 @@ +The gCube System - ${name} +------------------------------------------------------------ + +This work has been supported by the following European projects: iMarine (FP7-INFRASTRUCTURES-2011-2) + +Authors +------- + +Giancarlo Panichi (giancarlo.panichi@isti.cnr.it), CNR Pisa, +Istituto di Scienza e Tecnologie dell'Informazione "A. Faedo" + + +Version and Release Date +------------------------ + +v. ${version} (${release.date}) + +Description +----------- + +${project.description} + +Download information +-------------------- +Source code URL: ${scm.url} + + +Documentation +------------- + +${project.description} + + +Licensing +--------- + +This software is licensed under the terms you may find in the file named "LICENSE" in this directory. + + + diff --git a/templates/changelog.xml b/templates/changelog.xml new file mode 100644 index 0000000..6d1f54c --- /dev/null +++ b/templates/changelog.xml @@ -0,0 +1,6 @@ + + + First Release + + \ No newline at end of file diff --git a/templates/descriptor.xml b/templates/descriptor.xml new file mode 100644 index 0000000..b978636 --- /dev/null +++ b/templates/descriptor.xml @@ -0,0 +1,39 @@ + + servicearchive + + tar.gz + + / + + + ${distroDirectory} + / + true + + README + LICENSE + INSTALL + MAINTAINERS + changelog.xml + + 755 + + + + + ${distroDirectory}/svnpath.txt + /${artifactId} + + + ${configDirectory}/profile.xml + / + + + target/${build.finalName}.${packaging} + /${artifactId} + + + \ No newline at end of file diff --git a/templates/profile.xml b/templates/profile.xml new file mode 100644 index 0000000..ffa3274 --- /dev/null +++ b/templates/profile.xml @@ -0,0 +1,29 @@ + + + + Service + + ${project.description} + PortletsUser + ${project.name} + 1.0.0 + + + ${project.description} + ${project.name} + ${version} + + ${project.groupId} + ${project.artifactId} + ${project.version} + + library + + ${project.build.finalName}.${project.packaging} + + + + + + + diff --git a/templates/svnpath.txt b/templates/svnpath.txt new file mode 100644 index 0000000..dcd0d22 --- /dev/null +++ b/templates/svnpath.txt @@ -0,0 +1 @@ +${scm.url} \ No newline at end of file