Class JTableColumnByIdentifierQuery

java.lang.Object
org.fest.swing.query.JTableColumnByIdentifierQuery

public final class JTableColumnByIdentifierQuery extends Object
Understands an action that returns the index of a column in a JTable whose identifier matches the given one.

Note: Methods in this class are not executed in the event dispatch thread (EDT.) Clients are responsible for invoking them in the EDT.

See Also:
  • Constructor Details

    • JTableColumnByIdentifierQuery

      private JTableColumnByIdentifierQuery()
  • Method Details

    • columnIndexByIdentifier

      @RunsInCurrentThread public static int columnIndexByIdentifier(JTable table, Object identifier)
      Returns the index of a column in a JTable whose identifier matches the given one.
      Parameters:
      table - the given JTable.
      identifier - the column identifier.
      Returns:
      the index of a column with a matching identifier. Otherwise it returns -1.