org.fest.swing.driver
Class JTableComboBoxEditorCellWriter

java.lang.Object
  extended by org.fest.swing.driver.AbstractJTableCellWriter
      extended by org.fest.swing.driver.JTableComboBoxEditorCellWriter
All Implemented Interfaces:
JTableCellWriter

public class JTableComboBoxEditorCellWriter
extends AbstractJTableCellWriter

Understands an implementation of JTableCellWriter that knows how to use JComboBoxes as cell editors.

Author:
Alex Ruiz, Yvonne Wang

Field Summary
 
Fields inherited from class org.fest.swing.driver.AbstractJTableCellWriter
location, robot
 
Constructor Summary
JTableComboBoxEditorCellWriter(Robot robot)
           
 
Method Summary
 void enterValue(JTable table, int row, int column, String value)
          Enters the given value at the given cell of the JTable.
 void startCellEditing(JTable table, int row, int column)
          Starts editing the given cell of the JTable.
 
Methods inherited from class org.fest.swing.driver.AbstractJTableCellWriter
cancelCellEditing, cannotFindOrActivateEditor, cellEditor, cellEditor, cellEditor, cellLocation, editor, editorForCell, scrollToCell, stopCellEditing, validate, waitForEditorActivation, waitForEditorActivation
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JTableComboBoxEditorCellWriter

public JTableComboBoxEditorCellWriter(Robot robot)
Method Detail

enterValue

@RunsInEDT
public void enterValue(JTable table,
                                 int row,
                                 int column,
                                 String value)
Enters the given value at the given cell of the JTable. To edit a cell using this method, it is not necessary to call JTableCellWriter.startCellEditing(JTable, int, int) or JTableCellWriter.stopCellEditing(JTable, int, int).

Parameters:
table - the target JTable.
row - the row index of the cell.
column - the column index of the cell.
value - the value to enter.

startCellEditing

@RunsInEDT
public void startCellEditing(JTable table,
                                       int row,
                                       int column)
Starts editing the given cell of the JTable. This method should be called before manipulating the Component returned by JTableCellWriter.editorForCell(JTable, int, int).

Parameters:
table - the target JTable.
row - the row index of the cell.
column - the column index of the cell.
See Also:
JTableCellWriter.editorForCell(JTable, int, int)


Copyright © 2007-2011 FEST (Fixtures for Easy Software Testing). All Rights Reserved.