| Package | Description | 
|---|---|
| javax.swing | Provides a set of "lightweight"
(all-Java language) components that,
to the maximum degree possible, work the same on all platforms. | 
| javax.swing.event | Provides for events fired by Swing components. | 
| javax.swing.table | Provides classes and interfaces for dealing with
 javax.swing.JTable. | 
| Modifier and Type | Field and Description | 
|---|---|
| protected TableColumnModel | JTable. columnModelThe  TableColumnModelof the table. | 
| Modifier and Type | Method and Description | 
|---|---|
| protected TableColumnModel | JTable. createDefaultColumnModel()Returns the default column model object, which is
 a  DefaultTableColumnModel. | 
| TableColumnModel | JTable. getColumnModel()Returns the  TableColumnModelthat contains all column information
 of this table. | 
| Modifier and Type | Method and Description | 
|---|---|
| void | JTable. setColumnModel(TableColumnModel columnModel)Sets the column model for this table to  newModeland registers
 for listener notifications from the new column model. | 
| Constructor and Description | 
|---|
| JTable(TableModel dm,
      TableColumnModel cm)Constructs a  JTablethat is initialized withdmas the data model,cmas the column model, and a default selection model. | 
| JTable(TableModel dm,
      TableColumnModel cm,
      ListSelectionModel sm)Constructs a  JTablethat is initialized withdmas the data model,cmas the
 column model, andsmas the selection model. | 
| Constructor and Description | 
|---|
| TableColumnModelEvent(TableColumnModel source,
                     int from,
                     int to)Constructs a  TableColumnModelEventobject. | 
| Modifier and Type | Class and Description | 
|---|---|
| class  | DefaultTableColumnModelThe standard column-handler for a  JTable. | 
| Modifier and Type | Field and Description | 
|---|---|
| protected TableColumnModel | JTableHeader. columnModelThe  TableColumnModelof the table header. | 
| Modifier and Type | Method and Description | 
|---|---|
| protected TableColumnModel | JTableHeader. createDefaultColumnModel()Returns the default column model object which is
  a  DefaultTableColumnModel. | 
| TableColumnModel | JTableHeader. getColumnModel()Returns the  TableColumnModelthat contains all column information
 of this table header. | 
| Modifier and Type | Method and Description | 
|---|---|
| void | JTableHeader. setColumnModel(TableColumnModel columnModel)Sets the column model for this table to  newModeland registers
  for listener notifications from the new column model. | 
| Constructor and Description | 
|---|
| JTableHeader(TableColumnModel cm)Constructs a  JTableHeaderwhich is initialized withcmas the column model. | 
 Submit a bug or feature 
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
 Copyright © 1993, 2017, Oracle and/or its affiliates.  All rights reserved. Use is subject to license terms. Also see the documentation redistribution policy.