/** * * @param row */ public void addRow(AbstractGraphRow row) { ((ObjectTableModel) dataModel).addRow(row); }
/** * Add a single file to the table * @param f The name of the file to be added */ public void addFilename(String f) { tableModel.addRow(f); }
/** * * @param row */ public void addRow(AbstractGraphRow row) { ((ObjectTableModel) dataModel).addRow(row); }
@Override public void actionPerformed(ActionEvent e) { try { model.addRow(clazz.newInstance()); removeButton.setEnabled(true); clearButton.setEnabled(true); } catch(Exception err) { log.error("The class type given to TableEditor was not instantiable.", err); } } }
public void setRows(Iterable<?> rows) { // used by TableEditor clearData(); for(Object val : rows) { addRow(val); } } }
/** * Clears this visualizer and its model, and forces a repaint of the table. */ @Override public void clearData() { synchronized (lock) { model.clearData(); tableRows.clear(); tableRows.put(TOTAL_ROW_LABEL, new SamplingStatCalculator( TOTAL_ROW_LABEL)); model.addRow(tableRows.get(TOTAL_ROW_LABEL)); } }
/** * Clears this visualizer and its model, and forces a repaint of the table. */ @Override public void clearData() { synchronized (lock) { model.clearData(); tableRows.clear(); newRows.clear(); tableRows.put(TOTAL_ROW_LABEL, new SamplingStatCalculator(TOTAL_ROW_LABEL)); model.addRow(tableRows.get(TOTAL_ROW_LABEL)); } }
/** * Clears this visualizer and its model, and forces a repaint of the table. */ @Override public final void clearData() { synchronized (tableRows) { statModel.clearData(); tableRows.clear(); tableRows.put(TOTAL_ROW_LABEL, new SamplingStatCalculator(TOTAL_ROW_LABEL)); statModel.addRow(tableRows.get(TOTAL_ROW_LABEL)); } }
/** * Clears this visualizer and its model, and forces a repaint of the table. */ @Override public final void clearData() { synchronized (tableRows) { statModel.clearData(); tableRows.clear(); tableRows.put(TOTAL_ROW_LABEL, new SamplingStatCalculator(TOTAL_ROW_LABEL)); statModel.addRow(tableRows.get(TOTAL_ROW_LABEL)); } }
/** * Clears this visualizer and its model, and forces a repaint of the table. */ @Override public void clearData() { synchronized (lock) { model.clearData(); tableRows.clear(); newRows.clear(); tableRows.put(TOTAL_ROW_LABEL, new SamplingStatCalculator(TOTAL_ROW_LABEL)); model.addRow(tableRows.get(TOTAL_ROW_LABEL)); } }
/** * Clears this visualizer and its model, and forces a repaint of the table. */ @Override public void clearData() { synchronized (lock) { model.clearData(); tableRows.clear(); tableRows.put(TOTAL_ROW_LABEL, new SamplingStatCalculator( TOTAL_ROW_LABEL)); model.addRow(tableRows.get(TOTAL_ROW_LABEL)); } }
/** * Clears this visualizer and its model, and forces a repaint of the table. */ @Override public void clearData() { //Synch is needed because a clear can occur while add occurs synchronized (lock) { model.clearData(); newRows.clear(); tableRows.clear(); tableRows.put(TOTAL_ROW_LABEL, new Calculator(TOTAL_ROW_LABEL)); model.addRow(tableRows.get(TOTAL_ROW_LABEL)); } dataChanged = true; }
private void setUpData(){ tableModel.clearData(); Properties p = null; if (systemButton.isSelected()){ p = System.getProperties(); } if (jmeterButton.isSelected()) { p = JMeterUtils.getJMeterProperties(); } if (p == null) { return; } Set<Map.Entry<Object, Object>> s = p.entrySet(); List<Map.Entry<Object, Object>> al = new ArrayList<>(s); Collections.sort(al, new Comparator<Map.Entry<Object, Object>>(){ @Override public int compare(Map.Entry<Object, Object> o1, Map.Entry<Object, Object> o2) { String m1 = (String) o1.getKey(); String m2 = (String) o2.getKey(); return m1.compareTo(m2); } }); for (Map.Entry<Object, Object> row : al) { tableModel.addRow(row); } }
/** * Add a new argument row to the table. */ private void addArgument() { // If a table cell is being edited, we should accept the current value // and stop the editing before adding a new row. GuiUtils.stopTableEditing(table); tableModel.addRow(makeNewLDAPArgument()); // Enable DELETE (which may already be enabled, but it won't hurt) delete.setEnabled(true); // Highlight (select) the appropriate row. int rowToSelect = tableModel.getRowCount() - 1; table.setRowSelectionInterval(rowToSelect, rowToSelect); }
/** * A newly created component can be initialized with the contents of a * HTTPSamplerBase object by calling this method. The component is responsible for * querying the Test Element object for the relevant information to display * in its GUI. * * @param testElement the HTTPSamplerBase to be used to configure the GUI */ public void configure(TestElement testElement) { if (testElement instanceof HTTPSamplerBase) { HTTPSamplerBase base = (HTTPSamplerBase) testElement; tableModel.clearData(); for(HTTPFileArg file : base.getHTTPFiles()){ tableModel.addRow(file); } checkDeleteAndBrowseStatus(); } }
/** * Add a new file row to the table. */ private void addFile(String path) { // If a table cell is being edited, we should accept the current value // and stop the editing before adding a new row. GuiUtils.stopTableEditing(table); tableModel.addRow(new HTTPFileArg(path)); checkDeleteAndBrowseStatus(); // Highlight (select) the appropriate row. int rowToSelect = tableModel.getRowCount() - 1; table.setRowSelectionInterval(rowToSelect, rowToSelect); }
/** * A newly created component can be initialized with the contents of a Test * Element object by calling this method. The component is responsible for * querying the Test Element object for the relevant information to display * in its GUI. * * @param el the TestElement to configure */ @Override public void configure(TestElement el) { super.configure(el); if (el instanceof Arguments) { tableModel.clearData(); for (JMeterProperty jMeterProperty : (Arguments) el) { Argument arg = (Argument) jMeterProperty.getObjectValue(); tableModel.addRow(arg); } } checkButtonsStatus(); }
@Override public void configure(TestElement el) { super.configure(el); if (el instanceof Arguments) { tableModel.clearData(); HTTPArgument.convertArgumentsToHTTP((Arguments) el); for (JMeterProperty jMeterProperty : ((Arguments) el).getArguments()) { HTTPArgument arg = (HTTPArgument) jMeterProperty.getObjectValue(); tableModel.addRow(arg); } } checkButtonsStatus(); }
/** * Add a new argument row to the table. */ protected void addArgument() { // If a table cell is being edited, we should accept the current value // and stop the editing before adding a new row. GuiUtils.stopTableEditing(table); tableModel.addRow(makeNewArgument()); checkButtonsStatus(); // Highlight (select) and scroll to the appropriate row. int rowToSelect = tableModel.getRowCount() - 1; table.setRowSelectionInterval(rowToSelect, rowToSelect); table.scrollRectToVisible(table.getCellRect(rowToSelect, 0, true)); }
/** * A newly created component can be initialized with the contents of a Test * Element object by calling this method. The component is responsible for * querying the Test Element object for the relevant information to display * in its GUI. * * @param el * the TestElement to configure */ @Override public void configure(TestElement el) { super.configure(el); if (el instanceof LDAPArguments) { tableModel.clearData(); PropertyIterator iter = ((LDAPArguments) el).iterator(); while (iter.hasNext()) { LDAPArgument arg = (LDAPArgument) iter.next().getObjectValue(); tableModel.addRow(arg); } } checkDeleteStatus(); }