Class XYDatasetTableModel

    • Constructor Detail

      • XYDatasetTableModel

        public XYDatasetTableModel()
        Default constructor.
      • XYDatasetTableModel

        public XYDatasetTableModel​(TableXYDataset dataset)
        Creates a new table model based on the specified dataset.
        Parameters:
        dataset - the dataset.
    • Method Detail

      • setModel

        public void setModel​(TableXYDataset dataset)
        Sets the model (dataset).
        Parameters:
        dataset - the dataset.
      • getRowCount

        public int getRowCount()
        Returns the number of rows.
        Specified by:
        getRowCount in interface TableModel
        Returns:
        The row count.
      • getColumnCount

        public int getColumnCount()
        Gets the number of columns in the model.
        Specified by:
        getColumnCount in interface TableModel
        Returns:
        The number of columns in the model.
      • getValueAt

        public Object getValueAt​(int row,
                                 int column)
        Returns a value of the specified cell. Column 0 is the X axis, Columns 1 and over are the Y axis
        Specified by:
        getValueAt in interface TableModel
        Parameters:
        row - the row number.
        column - the column number.
        Returns:
        The value of the specified cell.
      • isCellEditable

        public boolean isCellEditable​(int row,
                                      int column)
        Returns a flag indicating whether or not the specified cell is editable.
        Specified by:
        isCellEditable in interface TableModel
        Overrides:
        isCellEditable in class AbstractTableModel
        Parameters:
        row - the row number.
        column - the column number.
        Returns:
        true if the specified cell is editable.