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

## org.ka2ddo.yaac.gui
Class TelemetryModel

    java.lang.Object
      javax.swing.table.AbstractTableModel
          org.ka2ddo.yaac.gui.TelemetryModel

All Implemented Interfaces:
  java.io.Serializable, javax.swing.table.TableModel, TrackerListener

    public class TelemetryModel

extends javax.swing.table.AbstractTableModel
implements TrackerListener

This class extracts the background data for reporting current telemetry data from telemetering stations. Each report consists of 2 rows with 14 columns. The first row contains the station-specific column titles (from the PARMS message). The second row contains the station callsign, the 5 scaled analog values, and the 8 boolean bits.

See Also:
  Serialized Form

Field Summary

Fields inherited from class javax.swing.table.AbstractTableModel
`listenerList`

Constructor Summary
`TelemetryModel()`

Method Summary
`int` | `getColumnCount()` Returns the number of columns in the model.
`java.lang.String` | `getColumnName(int column)` Returns the localized name for the column.
`int` | `getRowCount()` Returns the number of rows in the model.
`int` | `getTelemetryStationCount()` Get the number of monitored stations currently sending telemetry data.
`java.lang.Object` | `getValueAt(int rowIndex, int columnIndex)` Returns the value for the cell at `columnIndex` and `rowIndex`.
`void` | `messageAdded(StationState ss, int index, AX25Message msg)` Called when a Message is added to the history for a station in the tracker.
`void` | `messageDeleted(StationState ss, int index, AX25Message msg)` Called when a AX25Message is deleted from the history for a station in the tracker.
`void` | `removeTableModelListener(javax.swing.event.TableModelListener l)` Removes a listener from the list that's notified each time a change to the data model occurs.
`void` | `stationAdded(StationState ss, int index)` Called when a new station is initially added to the tracker.
`void` | `stationDeleted(StationState ss, int index)` Called when an existing station is deleted from the tracker.
`void` | `stationUpdated(StationState ss)` Called when an existing station is updated with new information in the tracker.

Methods inherited from class javax.swing.table.AbstractTableModel
`addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getColumnClass, getListeners, getTableModelListeners, isCellEditable, setValueAt`

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

Constructor Detail

### TelemetryModel

    public TelemetryModel()

Method Detail

### getTelemetryStationCount

    public int getTelemetryStationCount()

  Get the number of monitored stations currently sending telemetry data.

  Returns:
    station count

### getColumnName

    public java.lang.String getColumnName(int column)

  Returns the localized name for the column.

  Specified by:
    `getColumnName` in interface `javax.swing.table.TableModel`
  Overrides:
    `getColumnName` in class `javax.swing.table.AbstractTableModel`
  Parameters:
    `column` - the column being queried
  Returns:
    a string containing the name of `column`

### getColumnCount

    public int getColumnCount()

  Returns the number of columns in the model.

  Specified by:
    `getColumnCount` in interface `javax.swing.table.TableModel`
  Returns:
    the number of columns in the model
  See Also:
    `getRowCount()`

### getRowCount

    public int getRowCount()

  Returns the number of rows in the model. A `JTable` uses this method to determine how many rows it should display. This method should be quick, as it is called frequently during rendering.

  Specified by:
    `getRowCount` in interface `javax.swing.table.TableModel`
  Returns:
    the number of rows in the model
  See Also:
    `getColumnCount()`

### getValueAt

    public java.lang.Object getValueAt(int rowIndex,
                                       int columnIndex)

  Returns the value for the cell at `columnIndex` and `rowIndex`.

  Specified by:
    `getValueAt` in interface `javax.swing.table.TableModel`
  Parameters:
    `rowIndex` - the row whose value is to be queried
    `columnIndex` - the column whose value is to be queried
  Returns:
    the value Object at the specified cell

### messageAdded

    public void messageAdded(StationState ss,
                             int index,
                             AX25Message msg)

  Called when a Message is added to the history for a station in the tracker.

  Specified by:
    `messageAdded` in interface `TrackerListener`
  Parameters:
    `ss` - StationState containing the station's information
    `index` - zero-based index of the message added to the StationState object
    `msg` - APRS Message object being added to the tracker; note that non-APRS packets

### messageDeleted

    public void messageDeleted(StationState ss,
                               int index,
                               AX25Message msg)

  Called when a AX25Message is deleted from the history for a station in the tracker.

  Specified by:
    `messageDeleted` in interface `TrackerListener`
  Parameters:
    `ss` - StationState containing the station's information; the AX25Message will already be removed from the StationState object
    `index` - zero-based index of the message removed from the StationState object
    `msg` - APRS Message object being removed from the tracker; note that non-APRS packets that can still be decoded (such as OpenTRAC) will also be passed here; AX25Frames that cannot be decoded will pass null here

### stationAdded

    public void stationAdded(StationState ss,
                             int index)

  Called when a new station is initially added to the tracker.

  Specified by:
    `stationAdded` in interface `TrackerListener`
  Parameters:
    `ss` - StationState containing the station's information; the initial AX25Message will not yet be stored within the StationState object
    `index` - zero-based integer sequence number for this station in the StationTracker

### stationUpdated

    public void stationUpdated(StationState ss)

  Called when an existing station is updated with new information in the tracker.

  Specified by:
    `stationUpdated` in interface `TrackerListener`
  Parameters:
    `ss` - StationState containing the station's information; the new AX25Message will not yet be stored within the StationState object

### stationDeleted

    public void stationDeleted(StationState ss,
                               int index)

  Called when an existing station is deleted from the tracker.

  Specified by:
    `stationDeleted` in interface `TrackerListener`
  Parameters:
    `ss` - StationState containing the station's information
    `index` - zero-based integer sequence number for this station in the StationTracker

### removeTableModelListener

    public void removeTableModelListener(javax.swing.event.TableModelListener l)

  Removes a listener from the list that's notified each time a change to the data model occurs.

  Specified by:
    `removeTableModelListener` in interface `javax.swing.table.TableModel`
  Overrides:
    `removeTableModelListener` in class `javax.swing.table.AbstractTableModel`
  Parameters:
    `l` - the TableModelListener

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