public void columnAddStyleName(int rows, int cols) { HTMLTable table = createTable(rows, cols); resetTimer(); ColumnFormatter formatter = table.getColumnFormatter(); for (int i = 0; i < cols; i++) { formatter.addStyleName(i, "fooStyle"); } timing("column.addStyleName(" + rows + ", " + cols + ")"); }
public void setTextTiming(int rows, int columns) { resetTimer(); HTMLTable HTMLTable = createTable(rows, columns); for (int row = 0; row < rows; row++) { for (int column = 0; column < columns; column++) { HTMLTable.setText(row, column, "test"); } } timing(" setText(" + rows + "," + columns + ")"); }
public void addStyleName(int rows, int columns) { HTMLTable HTMLTable = createTable(rows, columns); resetTimer(); for (int row = 0; row < rows; row++) { for (int column = 0; column < columns; column++) { HTMLTable.getCellFormatter().addStyleName(row, column, "foo"); } } timing("addStyleName(" + rows + "," + columns + ")"); }
public void getStyleName(int rows, int columns) { System.out.println("Hybrid mode"); HTMLTable HTMLTable = createTable(rows, columns); resetTimer(); for (int row = 0; row < rows; row++) { for (int column = 0; column < columns; column++) { HTMLTable.getCellFormatter().getStyleName(row, column); } } timing("getStyleName(" + rows + "," + columns + ")"); }
public void setWidgetTiming(int rows, int columns) { resetTimer(); HTMLTable HTMLTable = createTable(rows, columns); RootPanel.get().add(HTMLTable); for (int row = 0; row < rows; row++) { for (int column = 0; column < columns; column++) { Label label = new Label(column + "i"); HTMLTable.setWidget(row, column, label); } } timing("setWidgetTiming(" + rows + "," + columns + ")"); }
@Override public void removeRow(int row) { super.removeRow(row); }
/** * Removes the specified cell from the table. * * @param row the row of the cell to remove * @param column the column of cell to remove * @throws IndexOutOfBoundsException */ @Override public void removeCell(int row, int column) { super.removeCell(row, column); }
public void addRow(String s) { textArea.append(s); if (htmlTable) { table.addRow(s); } }
public String endTable() { Assert.isTrue(htmlTable); String result = table.toHTMLTable().toString(); table.newTable(); return result; }