Massimiliano Assante 9 years ago
parent
commit
0e512c18a9
  1. 27
      .classpath
  2. 38142
      .gwt/.gwt-log
  3. 34
      .project
  4. 5
      .settings/com.google.gdt.eclipse.core.prefs
  5. 5
      .settings/com.google.gwt.eclipse.core.prefs
  6. 4
      .settings/org.eclipse.core.resources.prefs
  7. 6
      .settings/org.eclipse.jdt.core.prefs
  8. 5
      .settings/org.eclipse.m2e.core.prefs
  9. 0
      distro/INSTALL
  10. 6
      distro/LICENSE
  11. 2
      distro/MAINTAINERS
  12. 53
      distro/README
  13. 71
      distro/changelog.xml
  14. 48
      distro/descriptor.xml
  15. 25
      distro/profile.xml
  16. 1
      distro/svnpath.txt
  17. 57
      etc/profile.xml
  18. 245
      pom.xml
  19. 27
      src/main/java/org/gcube/portlets/user/workspace/WorkspaceTree.gwt.xml
  20. 1748
      src/main/java/org/gcube/portlets/user/workspace/client/AppControllerExplorer.java
  21. 202
      src/main/java/org/gcube/portlets/user/workspace/client/ConstantsExplorer.java
  22. 33
      src/main/java/org/gcube/portlets/user/workspace/client/TreeAsync.java
  23. 59
      src/main/java/org/gcube/portlets/user/workspace/client/event/AddFolderEvent.java
  24. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/AddFolderEventHandler.java
  25. 63
      src/main/java/org/gcube/portlets/user/workspace/client/event/AddSmartFolderEvent.java
  26. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/AddSmartFolderEventHandler.java
  27. 31
      src/main/java/org/gcube/portlets/user/workspace/client/event/BulkCreatorEvent.java
  28. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/BulkCreatorEventHandler.java
  29. 48
      src/main/java/org/gcube/portlets/user/workspace/client/event/CompletedFileUploadEvent.java
  30. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/CompletedFileUploadEventHandler.java
  31. 56
      src/main/java/org/gcube/portlets/user/workspace/client/event/CreateSharedFolderEvent.java
  32. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/CreateSharedFolderEventHandler.java
  33. 52
      src/main/java/org/gcube/portlets/user/workspace/client/event/CreateUrlEvent.java
  34. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/CreateUrlEventHandler.java
  35. 34
      src/main/java/org/gcube/portlets/user/workspace/client/event/DeleteBulkEvent.java
  36. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/DeleteBulkEventHandler.java
  37. 39
      src/main/java/org/gcube/portlets/user/workspace/client/event/DeleteItemEvent.java
  38. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/DeleteItemEventHandler.java
  39. 37
      src/main/java/org/gcube/portlets/user/workspace/client/event/DeleteMessageEvent.java
  40. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/DeleteMessageEventHandler.java
  41. 57
      src/main/java/org/gcube/portlets/user/workspace/client/event/DeleteSmartFolderEvent.java
  42. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/DeleteSmartFolderEventHandler.java
  43. 43
      src/main/java/org/gcube/portlets/user/workspace/client/event/ExpandFolderEvent.java
  44. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/ExpandFolderEventHandler.java
  45. 58
      src/main/java/org/gcube/portlets/user/workspace/client/event/FileDownloadEvent.java
  46. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/FileDownloadEventHandler.java
  47. 47
      src/main/java/org/gcube/portlets/user/workspace/client/event/FileUploadEvent.java
  48. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/FileUploadEventHandler.java
  49. 29
      src/main/java/org/gcube/portlets/user/workspace/client/event/FilterScopeEvent.java
  50. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/FilterScopeEventHandler.java
  51. 44
      src/main/java/org/gcube/portlets/user/workspace/client/event/ImagePreviewEvent.java
  52. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/ImagePreviewEventHandler.java
  53. 56
      src/main/java/org/gcube/portlets/user/workspace/client/event/MoveItemEvent.java
  54. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/MoveItemEventHandler.java
  55. 44
      src/main/java/org/gcube/portlets/user/workspace/client/event/OpenContextMenuTreeEvent.java
  56. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/OpenContextMenuTreeEventHandler.java
  57. 69
      src/main/java/org/gcube/portlets/user/workspace/client/event/OpenMessageEvent.java
  58. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/OpenMessageEventHandler.java
  59. 35
      src/main/java/org/gcube/portlets/user/workspace/client/event/OpenReportsEvent.java
  60. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/OpenReportsEventHandler.java
  61. 35
      src/main/java/org/gcube/portlets/user/workspace/client/event/OpenUrlEvent.java
  62. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/OpenUrlEventHandler.java
  63. 35
      src/main/java/org/gcube/portlets/user/workspace/client/event/PasteItemEvent.java
  64. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/PasteItemEventHandler.java
  65. 54
      src/main/java/org/gcube/portlets/user/workspace/client/event/PreviewMessageEvent.java
  66. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/PreviewMessageEventHandler.java
  67. 39
      src/main/java/org/gcube/portlets/user/workspace/client/event/RefreshFolderEvent.java
  68. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/RefreshItemEventHandler.java
  69. 59
      src/main/java/org/gcube/portlets/user/workspace/client/event/RenameItemEvent.java
  70. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/RenameItemEventHandler.java
  71. 29
      src/main/java/org/gcube/portlets/user/workspace/client/event/RenderForm.java
  72. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/RenderFormEventHandler.java
  73. 36
      src/main/java/org/gcube/portlets/user/workspace/client/event/SaveAttachmentsEvent.java
  74. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/SaveAttachmentsEventHandler.java
  75. 39
      src/main/java/org/gcube/portlets/user/workspace/client/event/SelectedItemEvent.java
  76. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/SelectedItemEventHandler.java
  77. 50
      src/main/java/org/gcube/portlets/user/workspace/client/event/SendMessageEvent.java
  78. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/SendMessageEventHandler.java
  79. 55
      src/main/java/org/gcube/portlets/user/workspace/client/event/SmartFolderSelectedEvent.java
  80. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/SmartFolderSelectedEventHandler.java
  81. 50
      src/main/java/org/gcube/portlets/user/workspace/client/event/SubTreeLoadedEvent.java
  82. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/SubTreeLoadedEventHandler.java
  83. 38
      src/main/java/org/gcube/portlets/user/workspace/client/event/SwitchViewEvent.java
  84. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/SwitchViewEventHandler.java
  85. 33
      src/main/java/org/gcube/portlets/user/workspace/client/event/UnShareFolderEvent.java
  86. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/UnShareFolderEventHandler.java
  87. 33
      src/main/java/org/gcube/portlets/user/workspace/client/event/UpdadeTreePanelLevelEvent.java
  88. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/UpdadeTreePanelLevelEventHandler.java
  89. 29
      src/main/java/org/gcube/portlets/user/workspace/client/event/WebDavUrlEvent.java
  90. 7
      src/main/java/org/gcube/portlets/user/workspace/client/event/WebDavUrlEventHandler.java
  91. 29
      src/main/java/org/gcube/portlets/user/workspace/client/interfaces/EventsTypeEnum.java
  92. 34
      src/main/java/org/gcube/portlets/user/workspace/client/interfaces/GXTCategoryItemInterface.java
  93. 62
      src/main/java/org/gcube/portlets/user/workspace/client/interfaces/GXTFolderItemTypeEnum.java
  94. 13
      src/main/java/org/gcube/portlets/user/workspace/client/interfaces/GuiEventInterface.java
  95. 40
      src/main/java/org/gcube/portlets/user/workspace/client/interfaces/SubscriberInterface.java
  96. 33
      src/main/java/org/gcube/portlets/user/workspace/client/interfaces/TreeAppControllerInterface.java
  97. 102
      src/main/java/org/gcube/portlets/user/workspace/client/model/BulkCreatorModel.java
  98. 54
      src/main/java/org/gcube/portlets/user/workspace/client/model/FileDetailsModel.java
  99. 61
      src/main/java/org/gcube/portlets/user/workspace/client/model/FileGridModel.java
  100. 272
      src/main/java/org/gcube/portlets/user/workspace/client/model/FileModel.java

27
.classpath

@ -0,0 +1,27 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="con" path="com.google.gwt.eclipse.core.GWT_CONTAINER"/>
<classpathentry including="**/*.java" kind="src" output="target/classes" path="src/main/java">
<attributes>
<attribute name="optional" value="true"/>
<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 kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6">
<attributes>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="con" path="org.eclipse.m2e.MAVEN2_CLASSPATH_CONTAINER">
<attributes>
<attribute name="maven.pomderived" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="output" path="target/classes"/>
</classpath>

38142
.gwt/.gwt-log

File diff suppressed because it is too large

34
.project

@ -0,0 +1,34 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>WorkspaceTree</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>com.google.gdt.eclipse.core.webAppProjectValidator</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>com.google.gwt.eclipse.core.gwtProjectValidator</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>org.eclipse.m2e.core.maven2Builder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.m2e.core.maven2Nature</nature>
<nature>org.eclipse.jdt.core.javanature</nature>
<nature>com.google.gwt.eclipse.core.gwtNature</nature>
</natures>
</projectDescription>

5
.settings/com.google.gdt.eclipse.core.prefs

@ -0,0 +1,5 @@
#Wed Jun 27 12:10:12 CEST 2012
eclipse.preferences.version=1
jarsExcludedFromWebInfLib=
warSrcDir=
warSrcDirIsOutput=true

5
.settings/com.google.gwt.eclipse.core.prefs

@ -0,0 +1,5 @@
#Mon May 07 16:37:03 CEST 2012
eclipse.preferences.version=1
entryPointModules=
filesCopiedToWebInfLib=gwt-servlet.jar
gwtCompileSettings=PGd3dC1jb21waWxlLXNldHRpbmdzPjxsb2ctbGV2ZWw+SU5GTzwvbG9nLWxldmVsPjxvdXRwdXQtc3R5bGU+T0JGVVNDQVRFRDwvb3V0cHV0LXN0eWxlPjxleHRyYS1hcmdzPjwhW0NEQVRBW11dPjwvZXh0cmEtYXJncz48dm0tYXJncz48IVtDREFUQVstWG14NTEybV1dPjwvdm0tYXJncz48ZW50cnktcG9pbnQtbW9kdWxlPm9yZy5nY3ViZS5wb3J0bGV0cy51c2VyLndvcmtzcGFjZS5Xb3Jrc3BhY2VUcmVlPC9lbnRyeS1wb2ludC1tb2R1bGU+PC9nd3QtY29tcGlsZS1zZXR0aW5ncz4\=

4
.settings/org.eclipse.core.resources.prefs

@ -0,0 +1,4 @@
#Wed Feb 06 15:12:34 CET 2013
eclipse.preferences.version=1
encoding//src/main/java=UTF-8
encoding/<project>=UTF-8

6
.settings/org.eclipse.jdt.core.prefs

@ -0,0 +1,6 @@
#Wed Feb 06 15:12:34 CET 2013
eclipse.preferences.version=1
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
org.eclipse.jdt.core.compiler.compliance=1.6
org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning
org.eclipse.jdt.core.compiler.source=1.6

5
.settings/org.eclipse.m2e.core.prefs

@ -0,0 +1,5 @@
#Wed Feb 06 15:08:01 CET 2013
activeProfiles=
eclipse.preferences.version=1
resolveWorkspaceProjects=true
version=1

0
distro/INSTALL

6
distro/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.

2
distro/MAINTAINERS

@ -0,0 +1,2 @@
* Federico De Faveri (federico.defaveri@isti.cnr.it), CNR Pisa, Istituto di Scienza e Tecnologie dell'Informazione "A. Faedo"
* Francesco Mangiacrapa (francesco.mangiacrapa@isti.cnr.it), CNR Pisa, Istituto di Scienza e Tecnologie dell'Informazione "A. Faedo"

53
distro/README

@ -0,0 +1,53 @@
The gCube System - WorkspaceTree
------------------------------------------------------------
This work is partially funded by the European Commission in the
context of the iMarine project (http://www.i-marine.eu).
Authors
-------
* Federico De Faveri (federico.defaveri@isti.cnr.it), CNR Pisa,
Istituto di Scienza e Tecnologie dell'Informazione "A. Faedo".
* Francesco Mangiacrapa (francesco.mangiacrapa@isti.cnr.it), CNR Pisa,
Istituto di Scienza e Tecnologie dell'Informazione "A. Faedo".
Version and Release Date
------------------------
v. 5.0.0
Description
-----------
The WorkspaceTree is a part of a portlet for users workspace management.
Download information
--------------------
Source code is available from SVN:
http://svn.research-infrastructures.eu/public/d4science/gcube/trunk/portlets/user/WorkspaceTree
Binaries can be downloaded from:
n/a
Documentation
-------------
Documentation is available on-line from the Projects Documentation Wiki:
https://gcube.wiki.gcube-system.org/gcube/index.php/Workspace
Licensing
---------
This software is licensed under the terms you may find in the file named "LICENSE" in this directory.

71
distro/changelog.xml

@ -0,0 +1,71 @@
<ReleaseNotes>
<Changeset component="org.gcube.portlets-user.workspace-portlet-tree.5-1-0" date="2012-09-21">
<Change>Old Send Message removed, added support for new mail sender</Change>
<Change>Bug fixed: upload file/archive</Change>
</Changeset>
<Changeset component="org.gcube.portlets-user.workspace-portlet-tree.5-0-0" date="2012-05-04">
<Change>#216 New version of Workspace Tree is developed using the GXT framework</Change>
<Change>#216 New tree is asynchronous</Change>
<Change>#216 Reviews tree GUI and adding new features</Change>
</Changeset>
<Changeset component="org.gcube.portlets-user.workspace-portlet-tree.4-3-0" date="2011-09-01">
<Change>#1740: ICIS / Download csv / added extension .xlw</Change>
</Changeset>
<Changeset component="org.gcube.portlets-user.workspace-portlet-tree.4-2-0" date="2011-07-01">
<Change>#1555: WorkflowTemplate and WorkflowReport required in Workspace Portlet</Change>
</Changeset>
<Changeset component="org.gcube.portlets-user.workspace-portlet-tree.4-1-0" date="2011-05-06">
<Change>Synch with others changes in HomeLibrary</Change>
<Change>GWT 2.2.0</Change>
</Changeset>
<Changeset component="org.gcube.portlets-user.workspace-portlet-tree.4-0-0" date="2011-02-07">
<Change>Removed Workspace and Basket type, replaced with folder option</Change>
<Change>Synch with others changes in HomeLibrary</Change>
</Changeset>
<Changeset component="org.gcube.portlets-user.workspace-portlet-tree.3-2-1" date="2010-11-09">
<Change>Added more checks on GWT model construction</Change>
</Changeset>
<Changeset component="org.gcube.portlets-user.workspace-portlet-tree.3-2-0" date="2010-10-22">
<Change>Enabled details panel for Report, ReportTemplate and AquaMapsItem workspace items</Change>
</Changeset>
<Changeset component="org.gcube.portlets-user.workspace-portlet-tree.3-1-0" date="2010-09-03">
<Change>#36: ICIS / Workspace / Upload an archive</Change>
<Change>Merged ThumbnailServlet and ImageServlet</Change>
<Change>#774: Workspace portlet tree - Open Report / Template redirect link not working</Change>
</Changeset>
<Changeset component="org.gcube.portlets-user.workspace-portlet-tree.3-0-0" date="2010-07-16">
<Change>Ported to GWT 2.0</Change>
<Change>Updated project structure to WebPortlet</Change>
<Change>Update to LifeRay portal</Change>
</Changeset>
<Changeset component="org.gcube.portlets-user.workspace-portlet-tree.2-6-0" date="2010-05-14">
<Change>#424: Workspace code refactoring an enanchement</Change>
<Change>refactored code</Change>
<Change>uniformed icons, no more specialized action icons</Change>
<Change>added more informations on items like AquaMapsItem, Report and Report Template</Change>
</Changeset>
<Changeset component="org.gcube.portlets-user.workspace-portlet-tree.2-5-0" date="2010-01-29">
<Change>gcube release 1.7.0</Change>
</Changeset>
<Changeset component="org.gcube.portlets-user.workspace-portlet-tree.2-4-0" date="2009-11-30">
<Change>gcube release 1.6.0</Change>
</Changeset>
<Changeset component="org.gcube.portlets-user.workspace-portlet-tree.2-3-0" date="2009-11-16">
<Change>gcube release 1.5.0</Change>
</Changeset>
<Changeset component="org.gcube.portlets-user.workspace-portlet-tree.2-2-0" date="2009-10-16">
<Change>gcube release</Change>
</Changeset>
<Changeset component="org.gcube.portlets-user.workspace-portlet-tree.2-1-1" date="2009-07-29">
<Change>gcube release 1.2.2</Change>
</Changeset>
<Changeset component="org.gcube.portlets-user.workspace-portlet-tree.2-1-0" date="2009-07-14">
<Change>gcube release 1.2.0</Change>
</Changeset>
<Changeset component="org.gcube.portlets-user.workspace-portlet-tree.2-0-0" date="2009-05-19">
<Change>gcube release 1.2.0 rc1</Change>
</Changeset>
<Changeset component="org.gcube.portlets-user.workspace-portlet-tree.1-1-2" date="2009-01-12">
<Change>first release</Change>
</Changeset>
</ReleaseNotes>

48
distro/descriptor.xml

@ -0,0 +1,48 @@
<assembly
xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0 http://maven.apache.org/xsd/assembly-1.1.0.xsd">
<id>servicearchive</id>
<formats>
<format>tar.gz</format>
</formats>
<baseDirectory>/</baseDirectory>
<fileSets>
<fileSet>
<directory>${distroDirectory}</directory>
<outputDirectory>/</outputDirectory>
<useDefaultExcludes>true</useDefaultExcludes>
<includes>
<include>README</include>
<include>LICENSE</include>
<include>INSTALL</include>
<include>MAINTAINERS</include>
<include>changelog.xml</include>
</includes>
<fileMode>755</fileMode>
<filtered>true</filtered>
</fileSet>
<fileSet>
<directory>target/apidocs</directory>
<outputDirectory>/${artifactId}/doc/api</outputDirectory>
<useDefaultExcludes>true</useDefaultExcludes>
<fileMode>755</fileMode>
</fileSet>
</fileSets>
<files>
<file>
<source>${distroDirectory}/profile.xml</source>
<outputDirectory>./</outputDirectory>
<filtered>true</filtered>
</file>
<file>
<source>target/${build.finalName}.jar</source>
<outputDirectory>/${artifactId}</outputDirectory>
</file>
<file>
<source>${distroDirectory}/svnpath.txt</source>
<outputDirectory>/${artifactId}</outputDirectory>
<filtered>true</filtered>
</file>
</files>
</assembly>

25
distro/profile.xml

@ -0,0 +1,25 @@
<?xml version="1.0" encoding="UTF-8"?>
<Resource xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<ID></ID>
<Type>Library</Type>
<Profile>
<Description>${description}</Description>
<Class>PortletsUser</Class>
<Name>${artifactId}</Name>
<Version>1.0.0</Version>
<Packages>
<Software>
<Name>${artifactId}</Name>
<Version>${version}</Version>
<MavenCoordinates>
<groupId>${groupId}</groupId>
<artifactId>${artifactId}</artifactId>
<version>${version}</version>
</MavenCoordinates>
<Files>
<File>${build.finalName}.jar</File>
</Files>
</Software>
</Packages>
</Profile>
</Resource>

1
distro/svnpath.txt

@ -0,0 +1 @@
${scm.url}

57
etc/profile.xml

@ -0,0 +1,57 @@
<?xml version="1.0" encoding="UTF-8"?>
<Resource xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="service.xsd">
<ID/>
<Type>Service</Type>
<Profile>
<Description>Workspace Portlet Tree</Description>
<Class>Portal</Class>
<Name>WorkspacePortletTree</Name>
<Version>1.0.0</Version>
<Packages>
<Software>
<Description>WorkspaceTree</Description>
<Name>WorkspaceTree</Name>
<Version>5.1.0</Version>
<Dependencies>
<Dependency>
<Service>
<Class>ApplicationSupportLayer</Class>
<Name>ASLCore</Name>
<Version>1.0.0</Version>
</Service>
<Package>ASLCore</Package>
<Version>[2.0.0,3.0.0)</Version>
<Scope level="GHN"/>
<Optional>false</Optional>
</Dependency>
<Dependency>
<Service>
<Class>PortletsUser</Class>
<Name>HomeLibrary</Name>
<Version>1.0.0</Version>
</Service>
<Package>HomeLibrary</Package>
<Version>[5.0.0,6.0.0)</Version>
<Scope level="GHN"/>
<Optional>false</Optional>
</Dependency>
<Dependency>
<Service>
<Class>ExternalSoftware</Class>
<Name>commons-fileupload</Name>
<Version>1.02.01</Version>
</Service>
<Package>commons-fileupload</Package>
<Version>1.02.01</Version>
<Scope level="GHN"/>
<Optional>false</Optional>
</Dependency>
</Dependencies>
<Files>
<File>lib/WorkspaceTree.jar</File>
</Files>
</Software>
</Packages>
</Profile>
</Resource>

245
pom.xml

@ -0,0 +1,245 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<artifactId>maven-parent</artifactId>
<groupId>org.gcube.tools</groupId>
<version>1.0.0</version>
<relativePath />
</parent>
<groupId>org.gcube.portlets.user</groupId>
<artifactId>workspace-tree-widget</artifactId>
<version>6.0.0-SNAPSHOT</version>
<name>gCube Workspace Tree Widget</name>
<description>
gCube Workspace Tree Widget.
</description>
<scm>
<connection>scm:svn:http://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/${project.artifactId}</connection>
<developerConnection>scm:https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/${project.artifactId}</developerConnection>
<url>http://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/${project.artifactId}</url>
</scm>
<properties>
<!-- Convenience property to set the GWT version -->
<gwtVersion>2.4.0</gwtVersion>
<distroDirectory>distro</distroDirectory>
<!-- GWT needs at least java 1.6 -->
<maven.compiler.source>1.6</maven.compiler.source>
<maven.compiler.target>1.6</maven.compiler.target>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
</properties>
<dependencies>
<!-- This dependency is needed to use GWT UI BInder without old Xerces
version of gCore complaining -->
<dependency>
<groupId>xerces</groupId>
<artifactId>xercesImpl</artifactId>
<version>2.9.1</version>
<scope>provided</scope>
</dependency>
<!-- Google Web Toolkit (GWT) -->
<dependency>
<groupId>com.google.gwt</groupId>
<artifactId>gwt-user</artifactId>
<version>${gwtVersion}</version>
<!-- "provided" so that we don't deploy -->
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.sencha.gxt</groupId>
<artifactId>gxt</artifactId>
<version>2.2.5</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.gcube.portal</groupId>
<artifactId>custom-portal-handler</artifactId>
<version>[1.2.0-SNAPSHOT, 2.0.0-SNAPSHOT)</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.gcube.portlets.user</groupId>
<artifactId>gcube-widgets</artifactId>
<version>[1.4.0-SNAPSHOT, 2.0.0-SNAPSHOT)</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.gcube.applicationsupportlayer</groupId>
<artifactId>aslcore</artifactId>
<version>[3.2.0-SNAPSHOT, 4.0.0-SNAPSHOT)</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.gcube.portlets.user</groupId>
<artifactId>home-library</artifactId>
<version>[4.3.0-SNAPSHOT, 5.0.0-SNAPSHOT)</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.gcube.portlets.user</groupId>
<artifactId>home-library-jcr</artifactId>
<version>[1.3.0-SNAPSHOT, 2.0.0-SNAPSHOT)</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>commons-fileupload</groupId>
<artifactId>commons-fileupload</artifactId>
<version>1.2.2</version>
</dependency>
<dependency>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
<version>1.2.16</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-log4j12</artifactId>
<version>1.6.4</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>1.6.4</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>com.liferay.portal</groupId>
<artifactId>portal-service</artifactId>
<version>6.0.6</version>
<scope>provided</scope>
</dependency>
</dependencies>
<build>
<resources>
<resource>
<directory>src/main/java</directory>
<includes>
<include>**/*.*</include>
</includes>
</resource>
</resources>
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.6</source>
<target>1.6</target>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>2.2</version>
<executions>
<execution>
<goals>
<goal>test-jar</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.12</version>
<configuration>
<skipTests>true</skipTests>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
<version>2.5</version>
<executions>
<execution>
<id>copy-profile</id>
<phase>install</phase>
<goals>
<goal>copy-resources</goal>
</goals>
<configuration>
<outputDirectory>target</outputDirectory>
<resources>
<resource>
<directory>${distroDirectory}</directory>
<filtering>true</filtering>
<includes>
<include>profile.xml</include>
</includes>
</resource>
</resources>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-assembly-plugin</artifactId>
<version>2.2</version>
<configuration>
<descriptors>
<descriptor>${distroDirectory}/descriptor.xml</descriptor>
</descriptors>
<archive>
<manifest>
<mainClass>fully.qualified.MainClass</mainClass>
</manifest>
</archive>
</configuration>
<executions>
<execution>
<id>servicearchive</id>
<phase>install</phase>
<goals>
<goal>single</goal>
</goals>
</execution>
</executions>
</plugin>
<!-- GWT Maven Plugin -->
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>gwt-maven-plugin</artifactId>
<!-- TODO: Update version to 2.5.0 once gwt-maven-plugin 2.5.0 final
is released (post-GWT 2.5.0) -->
<version>2.4.0</version>
<dependencies>
<dependency>
<groupId>com.google.gwt</groupId>
<artifactId>gwt-user</artifactId>
<version>${gwtVersion}</version>
</dependency>
<dependency>
<groupId>com.google.gwt</groupId>
<artifactId>gwt-dev</artifactId>
<version>${gwtVersion}</version>
</dependency>
</dependencies>
<!-- JS is only needed in the package phase, this speeds up testing -->
<executions>
<execution>
<phase>prepare-package</phase>
<goals>
<goal>resources</goal>
<goal>compile</goal>
</goals>
</execution>
</executions>
<!-- Plugin configuration. There are many available options, see gwt-maven-plugin
documentation at codehaus.org -->
<configuration>
</configuration>
</plugin>
</plugins>
</build>
</project>

27
src/main/java/org/gcube/portlets/user/workspace/WorkspaceTree.gwt.xml

@ -0,0 +1,27 @@
<?xml version="1.0" encoding="UTF-8"?>
<module rename-to='workspacetree'>
<!-- Inherit the core Web Toolkit stuff. -->
<inherits name='com.google.gwt.user.User'/>
<inherits name='com.google.gwt.resources.Resources' />
<!-- For development, a default of `DEBUG` is recommended
<inherits name="com.allen_sauer.gwt.log.gwt-log-DEBUG" />-->
<!-- Other module inherits -->
<!-- Moduel GXT -->
<inherits name='com.extjs.gxt.ui.GXT'/>
<servlet path="/WorkspaceService" class="org.gcube.portlets.user.workspace.server.GWTWorkspaceServiceImpl" />
<!--
<servlet path="/ImageService" class="org.gcube.portlets.user.workspace.server.ImageServlet" />
<servlet path="/MetadataService" class="org.gcube.portlets.user.workspace.server.MetadataServlet" />
-->
<servlet path="/UploadService" class="org.gcube.portlets.user.workspace.server.UploadServlet" />
<servlet path="/DownloadService" class="org.gcube.portlets.user.workspace.server.DownloadServlet" />
<servlet path="/ImageService" class="org.gcube.portlets.user.workspace.server.ImageServlet" />
<!-- Specify the paths for translatable code -->
<source path='client'/>
<source path='shared'/>
</module>

1748
src/main/java/org/gcube/portlets/user/workspace/client/AppControllerExplorer.java

File diff suppressed because it is too large

202
src/main/java/org/gcube/portlets/user/workspace/client/ConstantsExplorer.java

@ -0,0 +1,202 @@
package org.gcube.portlets.user.workspace.client;
import com.google.gwt.core.client.GWT;
/**
* @author Francesco Mangiacrapa francesco.mangiacrapa@isti.cnr.it
*
*/
public class ConstantsExplorer {
// public static final String FILE_SERVICE = GWT.getModuleBaseURL() + "fileservice";
public static final String RPC_WORKSPACE_SERVICE = GWT.getModuleBaseURL() + "rpcWorkspace";
public static final String UPLOAD_WORKSPACE_SERVICE = GWT.getModuleBaseURL() + "UploadService";
public static final String DOWNLOAD_WORKSPACE_SERVICE = GWT.getModuleBaseURL() + "DownloadService";
public static final String SERVER_ERROR = "Sorry, an error has occurred on the server when";
public static final String TRY_AGAIN = "Try again";
//MESSAGE DIALOG BOX constants
public static final String MESSAGE_CONFIRM_DELETE_ITEM = "Are you sure you want to delete item";
public static final String MESSAGE_CONFIRM_DELETE_SMART_FOLDER = "Are you sure you want to delete smart folder";
public static final String MESSAGE_ADD_SMART_FOLDER = "Add Smart Folder";
public static final String MESSAGE_ADD_FOLDER = "Add Folder";
public static final String MESSAGE_ADD_SHARED_FOLDER = "Add Shared Folder";
public static final String MESSAGE_ADD = "Add";
public static final String MESSAGE_ADD_FOLDER_IN = "Add Folder in: ";
public static final String MESSAGE_ITEM_NAME = "Item Name";
public static final String MESSAGE_RENAME = "Rename";
public static final String MESSAGE_DELETE_ITEM = "Delete Item";
public static final String MESSAGE_DELETE = "Delete";
public static final String MESSAGE_UPLOAD_FILE = "Upload File";
public static final String MESSAGE_UPLOAD_ARCHIVE = "Upload Archive";
public static final String MESSAGE_FOLDER_NAME = "Folder Name";
public static final String MESSAGE_SMART_FOLDER_NAME = "Smart Folder Name";
public static final String LOADING = "Loading";
public static final String LOADINGSTYLE = "x-mask-loading";
public static final String VALIDATINGOPERATION = "Validating operation";
public static final String MESSAGE_DOWNLOAD_ITEM = "Download Item";
public static final String MESSAGE_PREVIEW = "Preview";
public static final String MESSAGE_SHOW = "Show";
public static final String MESSAGE_OPEN_URL = "Open Url";
public static final String MESSAGE_ADD_URL = "Add Url";
public static final String MESSAGE_ADD_URL_IN = "Add Url in:";
public static final String MESSAGE_OPEN_REPORT_TEMPLATE = "Open R. Template";
public static final String MESSAGE_OPEN_REPORT = "Open Report";
public static final String MESSAGE_SEND_TO = "Send to";
public static final String MESSAGE_SENT_IN_DATE = "Sent in date";
public static final String MESSAGE_ADD_CONTACT = "Add Contact";
public static final String MESSAGE_ADD_SUBJECT = "Add Subject";
public static final String MESSAGE_ERROR_OCCURED = "Sorry an error has occurred while processing your request";
public static final String INFO = "Info";
public static final String MESSAGE_SEND_TO_OK = "Your message has been successfully delivered";
public static final String COPYITEM = "Copy";
public static final String PASTEITEM = "Paste";
public static final String MESSAGE_REFRESH_FOLDER = "Refresh Folder";
public static final String LISTATTACHMENTSNAMES = "Attachments Names";
public static final String LISTCONTACTSTOSTRING = "ListContactToString";
public static final String STATUS = "Status";
public static final String LOADER = "Loader";
public static final String DOWNLOADSTATE = "DownloadState";
public static final String NUMFAILS = "numfails";
public static final String NUMREQUESTS = "numrequests";
public static final String MESSAGE_WEBDAV_URL = "View Url WebDAV ";
public static final String URL_WEBDAV = "WebDAV URL";
public static final String MESSAGE_NAME_FORCE_APHANUMERIC = "Field name must be alphanumeric and not contain special chars!";
public static final String MESSAGE_SEARCH_FORCE_APHANUMERIC = "Field search must be alphanumeric and not contain special chars!";
public static final String MESSAGE_CREATE_NEW_MESSAGE = "Create New Message";
public static final String FORWARDTO = "Forward to";
public static final String MESSAGETYPE = "Message Type";
public static final String WEBDAVURLLINKREADMORE = "https://gcube.wiki.gcube-system.org/gcube/index.php/Acces_workspace_from_Desktop_(via_WebDAV)";
public static final String TITLEACCESSWEBDAV = "Access from Desktop";
public static final String ACCESSWEBDAVMSG = "Files and folders can be managed directly from the file explorer of your desktop operating system.";
public static final String FILEUPLOADHEADER = "File upload in: ";
public static final String FILE = "File";
public static final String ERROR = "Error";
public static final String NOFILESPECIFIED = "No file specified";
public static final String PROGRESS = "Progress";
public static final String SAVINGYOURFILE = "Saving your file";
public static final String PREVIEWOF = "Preview of: ";
public static final String ARCHIVEUPLOADHEADER = "Archive upload in: ";
public static final String ARCHIVE = "Archive";
public static final String DIALOG_DESCRIPTION = "Description";
public static final String DIALOG_NAME = "Name";
public static final String DIALOG_URL = "Url";
public static final String ERRORURLNOTREACHABLE = "Error: url is not reachable!";
//FILE MODEL e Smart Folder constants
public static final String ROOT = "root";
public static final String NAME = "Name";
public static final String TYPE = "Type";
public static final String ICON = "Icon";
public static final String SHORTCUTCATEGORY = "Category";
// public static final String GRIDCOLUMNTYPE = "Type";
public static final String IDENTIFIER = "identifier";
public static final String FOLDERITEMTYPE = "folderItemType";
public static final String PARENT = "parent";
public static final String ISDIRECTORY = "isDirectory";
public static final String SHAREUSERS = "shareUsers";
public static final String ISSHARED = "isShared";
public static final String LASTMODIFIED = "lastModified";
public static final String DESCRIPTION = "description";
public static final String OWNER = "owner";
public static final String QUERY = "query";
public static final String FOLDERNOTLOAD = "notload";
public static final String FOLDERLOADED = "loaded";
public static final String MARKASREAD = "MARKASREAD";
public static final String ISROOT = "ISROOT";
//GRID COLUMNS constants
public static final String GRIDCOLUMNCREATIONDATE = "Creation Date";
public static final String SIZE = "Size";
public static final String EMPTY = "EMPTY";
//ID CONTEXT MENU
public static final String INS = "INS"; //Insert Folder
public static final String ADD = "ADD";
public static final String REM = "REM";
public static final String UPL = "UPL"; //Upload File
public static final String DWL = "DWL";
public static final String PRW = "PRW";
public static final String RNM = "RNM";
public static final String ISHF = "ASHF"; //Insert shared Folder
public static final String SHR = "SHR"; //SHARE
public static final String USHR = "USHR"; //UNSHARE
public static final String UPA = "UPA"; //Upload Archive
public static final String LNK = "LNK";
public static final String SHW = "SHW";
public static final String CLK = "CLK"; //Add Url
public static final String ORT = "ORT"; //Open report template
public static final String ORP = "ORP"; //Open report
public static final String SDT = "SDT"; //Send to
public static final String DWM = "DWN"; //Get all new messages
public static final String MKR = "MKR"; //Mark as read
public static final String MKNR = "MKNR"; //Mark as not read
public static final String DLM = "DLM"; //Delete message
public static final String FWM = "FWM"; //Forward message
public static final String CPI = "CPI"; //copy item
public static final String PSI = "PSI"; //paste
public static final String RFH = "RFH"; //Refresh
public static final String WDV = "WDV"; //WebDav
public static final String CNM = "CNM"; //Create new message
//ID CONTEXT MENU IN GRID
public static final String OPM = "OPM"; //Open message
public static final String SVA = "SVA"; //Save attachs
public static final String MESSAGE_SAVE_ATTACHS = "Save Attachments";
//Toolbar Item Name
public static final String TREE = "Tree";
public static final String SMARTFOLDER = "Smart Folder";
public static final String MESSAGES = "Messages";
public static final String SHORTCUTVIEW = "Shortcut View";
public static final String TREEVIEW = "Tree View";
//Used in set value in session
public static final String IDTEMPLATE = "idtemplate";
public static final String TEMPLATECREATION = "template-creation";
public static final String IDREPORT = "idreport";
public static final String REPORTGENERATION = "report-generation";
//Info contact constant
public static final String LOGIN = "login";
//GRID COLUMN ADD CONTACT
public static final String GRIDCOLUMNLOGIN = "Login";
public static final String SUBJECT = "Subject";
public static final String FROM = "From";
public static final String DATE = "Date";
public static final String NUMATTACHS = "Num Attachs";
public static final String FROMLOGIN = "From Contact";
public static final String LISTCONTACTSTO = "ListContactsTo";
public static final String LISTATTACHS = "ListAttachs";
public static final String TEXTMESS = "TextMess";
public static final String ISREAD = "IsRead";
//Message grid and context menu
public static final String MESSAGE_GET_ALL_NEW_MESSAGES = "Get all new messages";
public static final String MESSAGE_MARK_AS_READ = "Mark as Read";
public static final String MESSAGE_MARK_AS_NOTREAD = "Mark as Not Read";
public static final String MESSAGE_DELETE_MESSAGE = "Delete Message";
public static final String MESSAGE_FORWARD_MESSAGE = "Forward Message";
public static final String MESSAGE_REPLY = "Reply";
public static final String MESSAGE_REPLY_ALL = "Reply All";
//USED in message model
public static final String ID = "id";
public static final String ATTACHS = "Attachs";
public static final Object NONE = "None";
public static final String ABSTRACTICON = "Abstract Icon";
public enum ViewSwitchType {Tree, SmartFolder, Messages};
}

33
src/main/java/org/gcube/portlets/user/workspace/client/TreeAsync.java

@ -0,0 +1,33 @@
package org.gcube.portlets.user.workspace.client;
import org.gcube.portlets.user.workspace.client.rpc.GWTWorkspaceService;
import org.gcube.portlets.user.workspace.client.rpc.GWTWorkspaceServiceAsync;
import com.extjs.gxt.ui.client.Registry;
import com.google.gwt.core.client.EntryPoint;
import com.google.gwt.core.client.GWT;
/**
* @author Francesco Mangiacrapa francesco.mangiacrapa@isti.cnr.it
* Entry point classes define <code>onModuleLoad()</code>.
*/
public class TreeAsync implements EntryPoint {
/**
* Create a remote service proxy to talk to the server-side
*/
private final GWTWorkspaceServiceAsync rpcWorkspaceService = (GWTWorkspaceServiceAsync) GWT.create(GWTWorkspaceService.class);
/**
* This is the entry point method.
*/
public void onModuleLoad() {
Registry.register(ConstantsExplorer.RPC_WORKSPACE_SERVICE, rpcWorkspaceService);
//UNCOMMENT FOLLOWING TO USE ONLY TREE
// AppControllerExplorer appController = new AppControllerExplorer();
// appController.go(RootPanel.get("treePanelWs"), true);
}
}

59
src/main/java/org/gcube/portlets/user/workspace/client/event/AddFolderEvent.java

@ -0,0 +1,59 @@
package org.gcube.portlets.user.workspace.client.event;
import org.gcube.portlets.user.workspace.client.interfaces.EventsTypeEnum;
import org.gcube.portlets.user.workspace.client.interfaces.GuiEventInterface;
import org.gcube.portlets.user.workspace.client.model.FileModel;
import org.gcube.portlets.user.workspace.client.model.FolderModel;
import com.google.gwt.event.shared.GwtEvent;
public class AddFolderEvent extends GwtEvent<AddFolderEventHandler> implements GuiEventInterface{
public static Type<AddFolderEventHandler> TYPE = new Type<AddFolderEventHandler>();
private FileModel fileSourceModel = null; //File or Folder source click
private FileModel parentFileModel = null;
private FolderModel newFolder;
// public AddFolderEvent(FolderModel newFolder, FolderModel parentFileModel) {
// this.newFolder = newFolder;
// this.parentFileModel = parentFileModel;
// }
public AddFolderEvent(FileModel fileSourceModel, FileModel parentFileModel) {
this.fileSourceModel = fileSourceModel;
this.parentFileModel = parentFileModel;
}
@Override
public Type<AddFolderEventHandler> getAssociatedType() {
// TODO Auto-generated method stub
return TYPE;
}
@Override
protected void dispatch(AddFolderEventHandler handler) {
handler.onAddItem(this);
}
@Override
public EventsTypeEnum getKey() {
return EventsTypeEnum.ADDED_FOLDER_EVENT;
}
public FileModel getFileSourceModel() {
return fileSourceModel;
}
public FileModel getParentFileModel() {
return parentFileModel;
}
public void setNewFolder(FolderModel folder){
this.newFolder = folder;
}
public FolderModel getNewFolder() {
return newFolder;
}
}

7
src/main/java/org/gcube/portlets/user/workspace/client/event/AddFolderEventHandler.java

@ -0,0 +1,7 @@
package org.gcube.portlets.user.workspace.client.event;
import com.google.gwt.event.shared.EventHandler;
public interface AddFolderEventHandler extends EventHandler {
void onAddItem(AddFolderEvent event);
}

63
src/main/java/org/gcube/portlets/user/workspace/client/event/AddSmartFolderEvent.java

@ -0,0 +1,63 @@
package org.gcube.portlets.user.workspace.client.event;
import com.google.gwt.event.shared.GwtEvent;
public class AddSmartFolderEvent extends GwtEvent<AddSmartFolderEventHandler>{
public static Type<AddSmartFolderEventHandler> TYPE = new Type<AddSmartFolderEventHandler>();
private String smartFolderName;
private String searchText;
private String workpaceFolderId;
private String description;
// public AddSmartFolderEvent(String smartFolderName, String searchText, String workpaceFolderId) {
//
// this.smartFolderName = smartFolderName;
// this.searchText = searchText;
// this.workpaceFolderId = workpaceFolderId;
// }
public AddSmartFolderEvent(String searchText) {
this.searchText = searchText;
}
@Override
public Type<AddSmartFolderEventHandler> getAssociatedType() {
return TYPE;
}
@Override
protected void dispatch(AddSmartFolderEventHandler handler) {
handler.onSaveSmartFolder(this);
}
public String getSmartFolderName() {
return smartFolderName;
}
public String getSearchText() {
return searchText;
}
public String getWorkpaceFolderId() {
return workpaceFolderId;
}
public void setSmartFolderName(String smartFolderName) {
this.smartFolderName = smartFolderName;
}
public void setWorkpaceFolderId(String workpaceFolderId) {
this.workpaceFolderId = workpaceFolderId;
}
public String getDescription() {
return description;
}
public void setDescription(String description) {
this.description = description;
}
}

7
src/main/java/org/gcube/portlets/user/workspace/client/event/AddSmartFolderEventHandler.java

@ -0,0 +1,7 @@
package org.gcube.portlets.user.workspace.client.event;
import com.google.gwt.event.shared.EventHandler;
public interface AddSmartFolderEventHandler extends EventHandler {
void onSaveSmartFolder(AddSmartFolderEvent saveSmartFolderEvent);
}

31
src/main/java/org/gcube/portlets/user/workspace/client/event/BulkCreatorEvent.java

@ -0,0 +1,31 @@
package org.gcube.portlets.user.workspace.client.event;
import java.util.List;
import org.gcube.portlets.user.workspace.client.model.BulkCreatorModel;
import com.google.gwt.event.shared.GwtEvent;
public class BulkCreatorEvent extends GwtEvent<BulkCreatorEventHandler> {
public static Type<BulkCreatorEventHandler> TYPE = new Type<BulkCreatorEventHandler>();
private List<BulkCreatorModel> listBulks;
public BulkCreatorEvent(List<BulkCreatorModel> listBulks) {
this.listBulks = listBulks;
}
@Override
public Type<BulkCreatorEventHandler> getAssociatedType() {
return TYPE;
}
@Override
protected void dispatch(BulkCreatorEventHandler handler) {
handler.onBulkCreator(this);
}
public List<BulkCreatorModel> getListBulks() {
return listBulks;
}
}

7
src/main/java/org/gcube/portlets/user/workspace/client/event/BulkCreatorEventHandler.java

@ -0,0 +1,7 @@
package org.gcube.portlets.user.workspace.client.event;
import com.google.gwt.event.shared.EventHandler;
public interface BulkCreatorEventHandler extends EventHandler {
void onBulkCreator(BulkCreatorEvent bulkCreatorEvent);
}

48
src/main/java/org/gcube/portlets/user/workspace/client/event/CompletedFileUploadEvent.java

@ -0,0 +1,48 @@
package org.gcube.portlets.user.workspace.client.event;
import org.gcube.portlets.user.workspace.client.interfaces.EventsTypeEnum;
import org.gcube.portlets.user.workspace.client.interfaces.GuiEventInterface;
import org.gcube.portlets.user.workspace.client.model.FileModel;
import com.google.gwt.event.shared.GwtEvent;
/**
* @author Francesco Mangiacrapa francesco.mangiacrapa@isti.cnr.it
*
*/
public class CompletedFileUploadEvent extends GwtEvent<CompletedFileUploadEventHandler> implements GuiEventInterface{
public static Type<CompletedFileUploadEventHandler> TYPE = new Type<CompletedFileUploadEventHandler>();
private FileModel parentFileModel;
private String itemIdentifier;
public CompletedFileUploadEvent(FileModel parent, String itemIdentifier) {
this.parentFileModel = parent;
this.itemIdentifier = itemIdentifier;
}
@Override
public Type<CompletedFileUploadEventHandler> getAssociatedType() {
return TYPE;
}
@Override
protected void dispatch(CompletedFileUploadEventHandler handler) {
handler.onCompletedFileUploadEvent(this);
}
@Override
public EventsTypeEnum getKey() {
return EventsTypeEnum.COMPLETED_FILE_UPLOAD_EVENT;
}
public FileModel getParentFileModel() {
return parentFileModel;
}
public String getItemIdentifier() {
return itemIdentifier;
}
}

7
src/main/java/org/gcube/portlets/user/workspace/client/event/CompletedFileUploadEventHandler.java

@ -0,0 +1,7 @@
package org.gcube.portlets.user.workspace.client.event;
import com.google.gwt.event.shared.EventHandler;
public interface CompletedFileUploadEventHandler extends EventHandler {
void onCompletedFileUploadEvent(CompletedFileUploadEvent completedFileUploadEvent);
}

56
src/main/java/org/gcube/portlets/user/workspace/client/event/CreateSharedFolderEvent.java

@ -0,0 +1,56 @@
package org.gcube.portlets.user.workspace.client.event;
import org.gcube.portlets.user.workspace.client.model.FileModel;
import com.google.gwt.event.shared.GwtEvent;
public class CreateSharedFolderEvent extends GwtEvent<CreateSharedFolderEventHandler>{
public static Type<CreateSharedFolderEventHandler> TYPE = new Type<CreateSharedFolderEventHandler>();
private FileModel fileSourceModel = null; //File or Folder source click
private FileModel parentFileModel = null;
private boolean isNewFolder;
public boolean isNewFolder() {
return isNewFolder;
}
@Override
public Type<CreateSharedFolderEventHandler> getAssociatedType() {
return TYPE;
}
@Override
protected void dispatch(CreateSharedFolderEventHandler handler) {
handler.onCreateSharedFolder(this);
}
/**
*
* @param fileSourceModel
* @param parentFileModel
* @param isNewFolder
*/
public CreateSharedFolderEvent(FileModel fileSourceModel, FileModel parentFileModel, boolean isNewFolder) {
this.fileSourceModel = fileSourceModel;
this.parentFileModel = parentFileModel;
this.isNewFolder = isNewFolder;
}
public FileModel getFileSourceModel() {
return fileSourceModel;
}
public FileModel getParentFileModel() {
return parentFileModel;
}
// public void setNewFolder(FolderModel folder){
// this.newFolder = folder;
// }
//
// public FolderModel getNewFolder() {
// return newFolder;
// }
}

7
src/main/java/org/gcube/portlets/user/workspace/client/event/CreateSharedFolderEventHandler.java

@ -0,0 +1,7 @@
package org.gcube.portlets.user.workspace.client.event;
import com.google.gwt.event.shared.EventHandler;
public interface CreateSharedFolderEventHandler extends EventHandler {
void onCreateSharedFolder(CreateSharedFolderEvent createSharedFolderEvent);
}

52
src/main/java/org/gcube/portlets/user/workspace/client/event/CreateUrlEvent.java

@ -0,0 +1,52 @@
package org.gcube.portlets.user.workspace.client.event;
import org.gcube.portlets.user.workspace.client.interfaces.EventsTypeEnum;
import org.gcube.portlets.user.workspace.client.interfaces.GuiEventInterface;
import org.gcube.portlets.user.workspace.client.model.FileModel;
import com.google.gwt.event.shared.GwtEvent;
/**
* @author Francesco Mangiacrapa francesco.mangiacrapa@isti.cnr.it
*
*/
public class CreateUrlEvent extends GwtEvent<CreateUrlEventHandler> implements GuiEventInterface{
public static Type<CreateUrlEventHandler> TYPE = new Type<CreateUrlEventHandler>();
private FileModel parentFileModel;
private String itemIdentifier;
public CreateUrlEvent(String itemIdentifier, FileModel parent) {
this.parentFileModel = parent;
this.itemIdentifier = itemIdentifier;
}
@Override
public Type<CreateUrlEventHandler> getAssociatedType() {
return TYPE;
}
@Override
protected void dispatch(CreateUrlEventHandler handler) {
handler.onClickCreateUrl(this);
}
public FileModel getParentFileModel() {
return parentFileModel;
}
public void setParentFileModel(FileModel parentFileModel) {
this.parentFileModel = parentFileModel;
}
@Override
public EventsTypeEnum getKey() {
return EventsTypeEnum.ADDED_FILE_EVENT;
}
public String getItemIdentifier() {
return itemIdentifier;
}
}

7
src/main/java/org/gcube/portlets/user/workspace/client/event/CreateUrlEventHandler.java

@ -0,0 +1,7 @@
package org.gcube.portlets.user.workspace.client.event;
import com.google.gwt.event.shared.EventHandler;
public interface CreateUrlEventHandler extends EventHandler {
void onClickCreateUrl(CreateUrlEvent createUrlEvent);
}

34
src/main/java/org/gcube/portlets/user/workspace/client/event/DeleteBulkEvent.java

@ -0,0 +1,34 @@
package org.gcube.portlets.user.workspace.client.event;
import com.google.gwt.event.shared.GwtEvent;
/**
* @author Francesco Mangiacrapa francesco.mangiacrapa@isti.cnr.it
*
*/
public class DeleteBulkEvent extends GwtEvent<DeleteBulkEventHandler> {
public static Type<DeleteBulkEventHandler> TYPE = new Type<DeleteBulkEventHandler>();
private String bulkId = null;
public DeleteBulkEvent(String bulkId) {
this.bulkId = bulkId;
}
@Override
public Type<DeleteBulkEventHandler> getAssociatedType() {
// TODO Auto-generated method stub
return TYPE;
}
@Override
protected void dispatch(DeleteBulkEventHandler handler) {
handler.onDeleteBulk(this);
}
public String getBulkId() {
return bulkId;
}
}

7
src/main/java/org/gcube/portlets/user/workspace/client/event/DeleteBulkEventHandler.java

@ -0,0 +1,7 @@
package org.gcube.portlets.user.workspace.client.event;
import com.google.gwt.event.shared.EventHandler;
public interface DeleteBulkEventHandler extends EventHandler {
void onDeleteBulk(DeleteBulkEvent deleteBulkEvent);
}

39
src/main/java/org/gcube/portlets/user/workspace/client/event/DeleteItemEvent.java

@ -0,0 +1,39 @@
package org.gcube.portlets.user.workspace.client.event;
import org.gcube.portlets.user.workspace.client.interfaces.EventsTypeEnum;
import org.gcube.portlets.user.workspace.client.interfaces.GuiEventInterface;
import org.gcube.portlets.user.workspace.client.model.FileModel;
import com.google.gwt.event.shared.GwtEvent;
public class DeleteItemEvent extends GwtEvent<DeleteItemEventHandler> implements GuiEventInterface{
public static Type<DeleteItemEventHandler> TYPE = new Type<DeleteItemEventHandler>();
private FileModel fileTarget = null;
public DeleteItemEvent(FileModel fileModel) {
this.fileTarget = fileModel;
}
@Override
public Type<DeleteItemEventHandler> getAssociatedType() {
// TODO Auto-generated method stub
return TYPE;
}
@Override
protected void dispatch(DeleteItemEventHandler handler) {
handler.onDeleteItem(this);
}
@Override
public EventsTypeEnum getKey() {
// TODO Auto-generated method stub
return EventsTypeEnum.DELETE_ITEM_EVENT;
}
public FileModel getFileTarget() {
return fileTarget;
}
}

7
src/main/java/org/gcube/portlets/user/workspace/client/event/DeleteItemEventHandler.java

@ -0,0 +1,7 @@
package org.gcube.portlets.user.workspace.client.event;
import com.google.gwt.event.shared.EventHandler;
public interface DeleteItemEventHandler extends EventHandler {
void onDeleteItem(DeleteItemEvent deleteItemEvent);
}

37
src/main/java/org/gcube/portlets/user/workspace/client/event/DeleteMessageEvent.java

@ -0,0 +1,37 @@
package org.gcube.portlets.user.workspace.client.event;
import org.gcube.portlets.user.workspace.client.interfaces.EventsTypeEnum;
import org.gcube.portlets.user.workspace.client.interfaces.GuiEventInterface;
import org.gcube.portlets.user.workspace.client.model.MessageModel;
import com.google.gwt.event.shared.GwtEvent;
public class DeleteMessageEvent extends GwtEvent<DeleteMessageEventHandler> implements GuiEventInterface{
public static Type<DeleteMessageEventHandler> TYPE = new Type<DeleteMessageEventHandler>();
private MessageModel messageTarget = null;
public DeleteMessageEvent(MessageModel messageModel) {
this.messageTarget = messageModel;
}
@Override
public Type<DeleteMessageEventHandler> getAssociatedType() {
return TYPE;
}
@Override
protected void dispatch(DeleteMessageEventHandler handler) {
handler.onDeleteMessage(this);
}
public MessageModel getMessageTarget() {
return messageTarget;
}
@Override
public EventsTypeEnum getKey() {
return EventsTypeEnum.DELETED_MESSAGE;
}
}

7
src/main/java/org/gcube/portlets/user/workspace/client/event/DeleteMessageEventHandler.java

@ -0,0 +1,7 @@
package org.gcube.portlets.user.workspace.client.event;
import com.google.gwt.event.shared.EventHandler;
public interface DeleteMessageEventHandler extends EventHandler {
void onDeleteMessage(DeleteMessageEvent deleteMessageEvent);
}

57
src/main/java/org/gcube/portlets/user/workspace/client/event/DeleteSmartFolderEvent.java

@ -0,0 +1,57 @@
package org.gcube.portlets.user.workspace.client.event;
import org.gcube.portlets.user.workspace.client.interfaces.EventsTypeEnum;
import org.gcube.portlets.user.workspace.client.interfaces.GuiEventInterface;
import com.google.gwt.event.shared.GwtEvent;
/**
* @author Francesco Mangiacrapa francesco.mangiacrapa@isti.cnr.it
*
*/
public class DeleteSmartFolderEvent extends GwtEvent<DeleteSmartFolderEventHandler> implements GuiEventInterface{
public static Type<DeleteSmartFolderEventHandler> TYPE = new Type<DeleteSmartFolderEventHandler>();
private String smartIdentifier;
private String smartName;
// public DeleteSmartFolderEvent(FileModel fileModel) {
// this.fileTarget = fileModel;
// }
public DeleteSmartFolderEvent(String identifier, String name) {
this.smartIdentifier = identifier;
this.smartName = name;
}
@Override
public Type<DeleteSmartFolderEventHandler> getAssociatedType() {
// TODO Auto-generated method stub
return TYPE;
}
@Override
protected void dispatch(DeleteSmartFolderEventHandler handler) {
handler.onDeleteItem(this);
}
@Override
public EventsTypeEnum getKey() {
// TODO Auto-generated method stub
return EventsTypeEnum.DELETE_SMARTFOLDER_ITEM_EVENT;
}
public String getSmartIdentifier() {
return smartIdentifier;
}
public String getSmartName() {
return smartName;
}
// public FileModel getFileTarget() {
// return fileTarget;
// }
}

7
src/main/java/org/gcube/portlets/user/workspace/client/event/DeleteSmartFolderEventHandler.java

@ -0,0 +1,7 @@
package org.gcube.portlets.user.workspace.client.event;
import com.google.gwt.event.shared.EventHandler;
public interface DeleteSmartFolderEventHandler extends EventHandler {
void onDeleteItem(DeleteSmartFolderEvent deleteSmartFolderEvent);
}

43
src/main/java/org/gcube/portlets/user/workspace/client/event/ExpandFolderEvent.java

@ -0,0 +1,43 @@
package org.gcube.portlets.user.workspace.client.event;
import org.gcube.portlets.user.workspace.client.interfaces.EventsTypeEnum;
import org.gcube.portlets.user.workspace.client.interfaces.GuiEventInterface;
import org.gcube.portlets.user.workspace.client.model.FolderModel;
import com.google.gwt.event.shared.GwtEvent;
/**
* @author Francesco Mangiacrapa francesco.mangiacrapa@isti.cnr.it
*
*/
public class ExpandFolderEvent extends GwtEvent<ExpandFolderEventHandler> implements GuiEventInterface{
public static Type<ExpandFolderEventHandler> TYPE = new Type<ExpandFolderEventHandler>();
private FolderModel folderTarget = null;
public ExpandFolderEvent(FolderModel folder) {
this.folderTarget = folder;
}
@Override
public Type<ExpandFolderEventHandler> getAssociatedType() {
// TODO Auto-generated method stub
return TYPE;
}
@Override
protected void dispatch(ExpandFolderEventHandler handler) {
handler.onExpandFolder(this);
}
@Override
public EventsTypeEnum getKey() {
// TODO Auto-generated method stub
return EventsTypeEnum.EXPANDED_FOLDER_EVENT;
}
public FolderModel getFolderTarget() {
return folderTarget;
}
}

7
src/main/java/org/gcube/portlets/user/workspace/client/event/ExpandFolderEventHandler.java

@ -0,0 +1,7 @@
package org.gcube.portlets.user.workspace.client.event;
import com.google.gwt.event.shared.EventHandler;
public interface ExpandFolderEventHandler extends EventHandler {
void onExpandFolder(ExpandFolderEvent expandFolderEvent);
}

58
src/main/java/org/gcube/portlets/user/workspace/client/event/FileDownloadEvent.java

@ -0,0 +1,58 @@
package org.gcube.portlets.user.workspace.client.event;
import com.google.gwt.event.shared.GwtEvent;
public class FileDownloadEvent extends GwtEvent<FileDownloadEventHandler> {
public static Type<FileDownloadEventHandler> TYPE = new Type<FileDownloadEventHandler>();
public enum DownloadType {SHOW, DOWNLOAD};
private String itemIdentifier = null;
private DownloadType downloadType;
private String itemName;
// private FileType fileType;
// public enum FileType {TREE, ATTACH};
public FileDownloadEvent(String itemIdentifier, String name, DownloadType downloadType) {
this.itemIdentifier = itemIdentifier;
this.downloadType = downloadType;
this.itemName = name;
// this.fileType = fileType;
}
@Override
public Type<FileDownloadEventHandler> getAssociatedType() {
return TYPE;
}
@Override
protected void dispatch(FileDownloadEventHandler handler) {
handler.onFileDownloadEvent(this);
}
public String getDownloadTypeToString() {
return downloadType.toString();
}
public DownloadType getDownloadType() {
return downloadType;
}
public String getItemIdentifier() {
return itemIdentifier;
}
public String getItemName() {
return itemName;
}
// public FileType getFileType() {
// return fileType;
// }
//
// public String getFileTypeToString() {
// return fileType.toString();
// }
}