diff --git a/.classpath b/.classpath index bd24964..198b6c9 100644 --- a/.classpath +++ b/.classpath @@ -17,16 +17,16 @@ + + + + + - - - - - diff --git a/.settings/org.eclipse.jdt.core.prefs b/.settings/org.eclipse.jdt.core.prefs index 107056a..e047f52 100644 --- a/.settings/org.eclipse.jdt.core.prefs +++ b/.settings/org.eclipse.jdt.core.prefs @@ -1,12 +1,12 @@ eclipse.preferences.version=1 org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7 org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve -org.eclipse.jdt.core.compiler.compliance=1.6 +org.eclipse.jdt.core.compiler.compliance=1.5 org.eclipse.jdt.core.compiler.debug.lineNumber=generate org.eclipse.jdt.core.compiler.debug.localVariable=generate org.eclipse.jdt.core.compiler.debug.sourceFile=generate org.eclipse.jdt.core.compiler.problem.assertIdentifier=error org.eclipse.jdt.core.compiler.problem.enumIdentifier=error org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning -org.eclipse.jdt.core.compiler.source=1.6 +org.eclipse.jdt.core.compiler.source=1.5 diff --git a/.settings/org.eclipse.wst.common.component b/.settings/org.eclipse.wst.common.component new file mode 100644 index 0000000..8952fad --- /dev/null +++ b/.settings/org.eclipse.wst.common.component @@ -0,0 +1,6 @@ + + + + + + diff --git a/.settings/org.eclipse.wst.common.project.facet.core.xml b/.settings/org.eclipse.wst.common.project.facet.core.xml new file mode 100644 index 0000000..a50949e --- /dev/null +++ b/.settings/org.eclipse.wst.common.project.facet.core.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/src/main/java/org/gcube/portlets/user/tdwx/client/TabularDataXController.java b/src/main/java/org/gcube/portlets/user/tdwx/client/TabularDataXController.java index 1f4066e..ec42f33 100644 --- a/src/main/java/org/gcube/portlets/user/tdwx/client/TabularDataXController.java +++ b/src/main/java/org/gcube/portlets/user/tdwx/client/TabularDataXController.java @@ -45,14 +45,13 @@ public class TabularDataXController { { eventBus.addHandler(OpenTableEvent.TYPE, new OpenTableEventHandler() { - @Override + public void onOpenTable(OpenTableEvent event) { doOpenTable(event.getTableId()); } }); eventBus.addHandler(CloseTableEvent.TYPE, new CloseTableEventHandler() { - @Override public void onCloseTable(CloseTableEvent event) { doCloseTable(); } @@ -63,14 +62,12 @@ public class TabularDataXController { { service.openTable(tdSessionId, tableId, new AsyncCallback() { - @Override public void onSuccess(TableDefinition result) { Log.trace("table definition: "+result); currentTable = result; eventBus.fireEvent(new TableReadyEvent(result)); } - @Override public void onFailure(Throwable caught) { eventBus.fireEvent(new FailureEvent(caught, "Tabledefinition loading failed.")); } @@ -81,12 +78,10 @@ public class TabularDataXController { { service.closeTable(tdSessionId, new AsyncCallback() { - @Override public void onFailure(Throwable caught) { eventBus.fireEvent(new FailureEvent(caught, "Table closing failed.")); } - @Override public void onSuccess(Void result) { Log.trace("table closed"); currentTable = null; diff --git a/src/main/java/org/gcube/portlets/user/tdwx/client/TabularDataXGridPanel.java b/src/main/java/org/gcube/portlets/user/tdwx/client/TabularDataXGridPanel.java index d9021e2..ae6d83a 100644 --- a/src/main/java/org/gcube/portlets/user/tdwx/client/TabularDataXGridPanel.java +++ b/src/main/java/org/gcube/portlets/user/tdwx/client/TabularDataXGridPanel.java @@ -194,7 +194,6 @@ public class TabularDataXGridPanel extends ContentPanel { protected void bindEventBus() { eventBus.addHandler(OpenTableEvent.TYPE, new OpenTableEventHandler() { - @Override public void onOpenTable(OpenTableEvent event) { doOpenTable(); } @@ -202,7 +201,6 @@ public class TabularDataXGridPanel extends ContentPanel { eventBus.addHandler(TableReadyEvent.TYPE, new TableReadyEventHandler() { - @Override public void onTableReady(TableReadyEvent event) { doTableReady(event.getTableDefinition()); } @@ -210,7 +208,7 @@ public class TabularDataXGridPanel extends ContentPanel { eventBus.addHandler(CloseTableEvent.TYPE, new CloseTableEventHandler() { - @Override + public void onCloseTable(CloseTableEvent event) { doCloseTable(); } @@ -309,7 +307,7 @@ public class TabularDataXGridPanel extends ContentPanel { Scheduler.get().scheduleDeferred(new ScheduledCommand() { - @Override + public void execute() { container.forceLayout(); } diff --git a/src/main/java/org/gcube/portlets/user/tdwx/client/config/TabularDataGridViewConfig.java b/src/main/java/org/gcube/portlets/user/tdwx/client/config/TabularDataGridViewConfig.java index 926866c..d4b4305 100644 --- a/src/main/java/org/gcube/portlets/user/tdwx/client/config/TabularDataGridViewConfig.java +++ b/src/main/java/org/gcube/portlets/user/tdwx/client/config/TabularDataGridViewConfig.java @@ -40,7 +40,6 @@ public class TabularDataGridViewConfig implements GridViewConfig { /** * {@inheritDoc} */ - @Override public String getColStyle(DataRow model, ValueProvider valueProvider, int rowIndex, int colIndex) { return ""; } @@ -48,7 +47,6 @@ public class TabularDataGridViewConfig implements GridViewConfig { /** * {@inheritDoc} */ - @Override public String getRowStyle(DataRow model, int rowIndex) { row.setDataRow(model); return rowStyleProvider.getRowStyle(row); diff --git a/src/main/java/org/gcube/portlets/user/tdwx/client/model/grid/DataRowModelKeyProvider.java b/src/main/java/org/gcube/portlets/user/tdwx/client/model/grid/DataRowModelKeyProvider.java index eedc455..30ff576 100644 --- a/src/main/java/org/gcube/portlets/user/tdwx/client/model/grid/DataRowModelKeyProvider.java +++ b/src/main/java/org/gcube/portlets/user/tdwx/client/model/grid/DataRowModelKeyProvider.java @@ -22,7 +22,7 @@ public class DataRowModelKeyProvider implements ModelKeyProvider { this.key = key; } - @Override + public String getKey(DataRow row) { return String.valueOf(row.get(key)); } diff --git a/src/main/java/org/gcube/portlets/user/tdwx/client/model/grid/DataRowPagingReader.java b/src/main/java/org/gcube/portlets/user/tdwx/client/model/grid/DataRowPagingReader.java index 9d0b8c8..ac21737 100644 --- a/src/main/java/org/gcube/portlets/user/tdwx/client/model/grid/DataRowPagingReader.java +++ b/src/main/java/org/gcube/portlets/user/tdwx/client/model/grid/DataRowPagingReader.java @@ -39,7 +39,7 @@ public class DataRowPagingReader implements DataReader converter = new JSonValueConverter(definition.getColumnsAsList()); } - @Override + public PagingLoadResult read(Object loadConfig, String data) { JSonTable jSonData = JSonTable.getJSonTable(data); JsArray array = jSonData.getRows(definition.getJsonRowsField()); diff --git a/src/main/java/org/gcube/portlets/user/tdwx/client/model/grid/DataRowReader.java b/src/main/java/org/gcube/portlets/user/tdwx/client/model/grid/DataRowReader.java index ae8256e..9d2c409 100644 --- a/src/main/java/org/gcube/portlets/user/tdwx/client/model/grid/DataRowReader.java +++ b/src/main/java/org/gcube/portlets/user/tdwx/client/model/grid/DataRowReader.java @@ -37,7 +37,6 @@ public class DataRowReader implements DataReader, String /** * {@inheritDoc} */ - @Override public ListLoadResult read(Object loadConfig, String data) { JSonTable jSonData = JSonTable.getJSonTable(data); JsArray array = jSonData.getRows(definition.getJsonRowsField()); diff --git a/src/main/java/org/gcube/portlets/user/tdwx/client/model/grid/DataRowValueProvider.java b/src/main/java/org/gcube/portlets/user/tdwx/client/model/grid/DataRowValueProvider.java index b9114b8..ce2699a 100644 --- a/src/main/java/org/gcube/portlets/user/tdwx/client/model/grid/DataRowValueProvider.java +++ b/src/main/java/org/gcube/portlets/user/tdwx/client/model/grid/DataRowValueProvider.java @@ -27,7 +27,6 @@ public class DataRowValueProvider implements ValueProvider { * {@inheritDoc} */ @SuppressWarnings("unchecked") - @Override public V getValue(DataRow row) { return (V)row.get(key); } @@ -35,7 +34,7 @@ public class DataRowValueProvider implements ValueProvider { /** * {@inheritDoc} */ - @Override + public void setValue(DataRow row, V value) { row.set(key, value); } @@ -43,7 +42,6 @@ public class DataRowValueProvider implements ValueProvider { /** * {@inheritDoc} */ - @Override public String getPath() { return key.getJSonIndex(); } diff --git a/src/main/java/org/gcube/portlets/user/tdwx/client/util/ColumnPositionComparator.java b/src/main/java/org/gcube/portlets/user/tdwx/client/util/ColumnPositionComparator.java index 22ed28d..563f0fe 100644 --- a/src/main/java/org/gcube/portlets/user/tdwx/client/util/ColumnPositionComparator.java +++ b/src/main/java/org/gcube/portlets/user/tdwx/client/util/ColumnPositionComparator.java @@ -28,7 +28,6 @@ public class ColumnPositionComparator implements Comparator { /** * {@inheritDoc} */ - @Override public int compare(ColumnDefinition c1, ColumnDefinition c2) { if (c1.getPosition() == c2.getPosition()) return 0; if (noPositionLast && c1.getPosition()<0) return 1; diff --git a/src/main/java/org/gcube/portlets/user/tdwx/client/util/LiveRowNumberer.java b/src/main/java/org/gcube/portlets/user/tdwx/client/util/LiveRowNumberer.java index 082293c..ebdcb64 100644 --- a/src/main/java/org/gcube/portlets/user/tdwx/client/util/LiveRowNumberer.java +++ b/src/main/java/org/gcube/portlets/user/tdwx/client/util/LiveRowNumberer.java @@ -43,13 +43,13 @@ public class LiveRowNumberer extends RowNumberer { int col = grid.getColumnModel().indexOf(this); ModelKeyProvider kp = (ModelKeyProvider) grid.getStore().getKeyProvider(); - int offset = getOffset(); + //int offset = getOffset(); for (int i = 0, len = grid.getStore().size(); i < len; i++) { Element cell = grid.getView().getCell(i, col); if (cell != null) { SafeHtmlBuilder sb = new SafeHtmlBuilder(); - int index = offset + i; + //int index = offset + i; getCell().render(new Context(i, col, kp.getKey(grid.getStore().get(i))), null, sb); cell.getFirstChildElement().setInnerHTML(sb.toSafeHtml().asString()); } diff --git a/src/main/java/org/gcube/portlets/user/tdwx/client/util/PagingLoadUrlEncoder.java b/src/main/java/org/gcube/portlets/user/tdwx/client/util/PagingLoadUrlEncoder.java index fa3c21f..c85d3fe 100644 --- a/src/main/java/org/gcube/portlets/user/tdwx/client/util/PagingLoadUrlEncoder.java +++ b/src/main/java/org/gcube/portlets/user/tdwx/client/util/PagingLoadUrlEncoder.java @@ -19,7 +19,7 @@ public class PagingLoadUrlEncoder implements DataWriter