Package org.geotools.swing.table
Class FeatureCollectionTableModel
- Object
-
- AbstractTableModel
-
- FeatureCollectionTableModel
-
- All Implemented Interfaces:
Serializable
,TableModel
public class FeatureCollectionTableModel extends AbstractTableModel
A SwingTableModel
to retrieve attribute values from each feature in a feature collection and cache them for aJTable
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description IOException
exception
-
Fields inherited from class AbstractTableModel
listenerList
-
-
Constructor Summary
Constructors Constructor Description FeatureCollectionTableModel(SimpleFeatureCollection features)
Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
dispose()
Cancel the running job, if anyint
getColumnCount()
Get the number of columns in the tableString
getColumnName(int column)
Retrieve the specified column nameint
getRowCount()
Get the number of rows in the tableObject
getValueAt(int rowIndex, int columnIndex)
Get the value of a specified table entry-
Methods inherited from class AbstractTableModel
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getColumnClass, getListeners, getTableModelListeners, isCellEditable, removeTableModelListener, setValueAt
-
-
-
-
Field Detail
-
exception
public IOException exception
-
-
Constructor Detail
-
FeatureCollectionTableModel
public FeatureCollectionTableModel(SimpleFeatureCollection features)
Constructor- Parameters:
features
- the feature collection to load into the table
-
-
Method Detail
-
dispose
public void dispose()
Cancel the running job, if any
-
getColumnName
public String getColumnName(int column)
Retrieve the specified column name- Specified by:
getColumnName
in interfaceTableModel
- Overrides:
getColumnName
in classAbstractTableModel
- Parameters:
column
- column index- Returns:
- the column name
-
getColumnCount
public int getColumnCount()
Get the number of columns in the table- Returns:
- the number of columns
-
getRowCount
public int getRowCount()
Get the number of rows in the table- Returns:
- the number of rows
-
getValueAt
public Object getValueAt(int rowIndex, int columnIndex)
Get the value of a specified table entry- Parameters:
rowIndex
- the row indexcolumnIndex
- the column index- Returns:
- the table entry
-
-