Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## nextapp.echo2.app.table
Class DefaultTableColumnModel

    java.lang.Object
      nextapp.echo2.app.table.DefaultTableColumnModel

All Implemented Interfaces:
  java.io.Serializable, TableColumnModel

    public class DefaultTableColumnModel

extends java.lang.Object
implements java.io.Serializable, TableColumnModel

The default `TableColumnModel` implementation.

See Also:
  Serialized Form

Field Summary
`protected EventListenerList` | `listenerList` A listener storage facility.

Constructor Summary
`DefaultTableColumnModel()` Creates a new DefaultTableColumnModel.

Method Summary
`void` | `addColumn(TableColumn column)` Adds a table column to the end of the model.
`void` | `addColumnModelListener(TableColumnModelListener l)` Adds a listener to be notified of updates to this `TableColumnModel`.
`protected void` | `fireColumnAdded(TableColumnModelEvent e)` Notifies `TableColumnModelListener`s that a column was added.
`protected void` | `fireColumnMoved(TableColumnModelEvent e)` Notifies `TableColumnModelListener`s that a column was moved.
`protected void` | `fireColumnRemoved(TableColumnModelEvent e)` Notifies `TableColumnModelListener`s that a column was removed.
`TableColumn` | `getColumn(int index)` Returns the `TableColumn` at the specified index.
`int` | `getColumnCount()` Returns the number of columns in the column model.
`int` | `getColumnIndex(java.lang.Object identifier)` Returns the index of the table column with the given identifier.
`java.util.Iterator` | `getColumns()` Returns an `Iterator` over the columns of the column model.
`void` | `moveColumn(int columnIndex, int newIndex)` Moves a table column to a new index within the model.
`void` | `removeColumn(TableColumn column)` Remove a table column from the model.
`void` | `removeColumnModelListener(TableColumnModelListener l)` Removes a listener from being notified of updates to this `TableColumnModel`.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### listenerList

    protected EventListenerList listenerList

  A listener storage facility.

Constructor Detail

### DefaultTableColumnModel

    public DefaultTableColumnModel()

  Creates a new DefaultTableColumnModel.

Method Detail

### addColumn

    public void addColumn(TableColumn column)

  Description copied from interface: `TableColumnModel`
  Adds a table column to the end of the model.

  Specified by:
    `addColumn` in interface `TableColumnModel`
  Parameters:
    `column` - the column to add
  See Also:
    `TableColumnModel.addColumn(nextapp.echo2.app.table.TableColumn)`

### addColumnModelListener

    public void addColumnModelListener(TableColumnModelListener l)

  Description copied from interface: `TableColumnModel`
  Adds a listener to be notified of updates to this `TableColumnModel`.

  Specified by:
    `addColumnModelListener` in interface `TableColumnModel`
  Parameters:
    `l` - the listener to add
  See Also:
    `TableColumnModel.addColumnModelListener(nextapp.echo2.app.event.TableColumnModelListener)`

### fireColumnAdded

    protected void fireColumnAdded(TableColumnModelEvent e)

  Notifies `TableColumnModelListener`s that a column was added.

  Parameters:
    `e` - the `TableColumnModelEvent` to fire

### fireColumnMoved

    protected void fireColumnMoved(TableColumnModelEvent e)

  Notifies `TableColumnModelListener`s that a column was moved.

  Parameters:
    `e` - the `TableColumnModelEvent` to fire

### fireColumnRemoved

    protected void fireColumnRemoved(TableColumnModelEvent e)

  Notifies `TableColumnModelListener`s that a column was removed.

  Parameters:
    `e` - the `TableColumnModelEvent` to fire

### getColumn

    public TableColumn getColumn(int index)

  Description copied from interface: `TableColumnModel`
  Returns the `TableColumn` at the specified index.

  Specified by:
    `getColumn` in interface `TableColumnModel`
  Parameters:
    `index` - the index
  Returns:
    the column
  See Also:
    `TableColumnModel.getColumn(int)`

### getColumnCount

    public int getColumnCount()

  Description copied from interface: `TableColumnModel`
  Returns the number of columns in the column model.

  Specified by:
    `getColumnCount` in interface `TableColumnModel`
  Returns:
    the number of columns
  See Also:
    `TableColumnModel.getColumnCount()`

### getColumnIndex

    public int getColumnIndex(java.lang.Object identifier)

  Description copied from interface: `TableColumnModel`
  Returns the index of the table column with the given identifier.

  Specified by:
    `getColumnIndex` in interface `TableColumnModel`
  Parameters:
    `identifier` - the identifier
  Returns:
    the index
  See Also:
    `TableColumnModel.getColumnIndex(java.lang.Object)`

### getColumns

    public java.util.Iterator getColumns()

  Description copied from interface: `TableColumnModel`
  Returns an `Iterator` over the columns of the column model.

  Specified by:
    `getColumns` in interface `TableColumnModel`
  Returns:
    the `Iterator`
  See Also:
    `TableColumnModel.getColumns()`

### moveColumn

    public void moveColumn(int columnIndex,
                           int newIndex)

  Description copied from interface: `TableColumnModel`
  Moves a table column to a new index within the model.

  Specified by:
    `moveColumn` in interface `TableColumnModel`
  Parameters:
    `columnIndex` - the index of the column to move
    `newIndex` - the new index of the specified column
  See Also:
    `TableColumnModel.moveColumn(int, int)`

### removeColumn

    public void removeColumn(TableColumn column)

  Description copied from interface: `TableColumnModel`
  Remove a table column from the model.

  Specified by:
    `removeColumn` in interface `TableColumnModel`
  Parameters:
    `column` - the column to remove
  See Also:
    `TableColumnModel.removeColumn(nextapp.echo2.app.table.TableColumn)`

### removeColumnModelListener

    public void removeColumnModelListener(TableColumnModelListener l)

  Description copied from interface: `TableColumnModel`
  Removes a listener from being notified of updates to this `TableColumnModel`.

  Specified by:
    `removeColumnModelListener` in interface `TableColumnModel`
  Parameters:
    `l` - the listener to remove
  See Also:
    `TableColumnModel.removeColumnModelListener(nextapp.echo2.app.event.TableColumnModelListener)`

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD