Class RowObject


  • public class RowObject
    extends java.lang.Object
    An object that represents a row in a table. Most tables used in the system create tables that use their own row objects (see AbstractSortedTableModel). This class exists to compensate for those models that do not do this, but instead rely on the classic Java TableModel method TableModel.getValueAt(int, int).

    For the best behavior, a table model implementation should extend AbstractSortedTableModel, as the system is written to work for those models. Use of this class as a workaround is a suitable default, but will not always result in the desired behavior. A major reason for this is that if any of the table's cell values change, the row objects that created for non-AbstractSortedTableModels will not be equal to those created before the data change. This causes some features to break, such as selection restoration after user edits.

    • Constructor Summary

      Constructors 
      Constructor Description
      RowObject()  
    • Constructor Detail

      • RowObject

        public RowObject()
    • Method Detail

      • createRowObject

        public static RowObject createRowObject​(javax.swing.table.TableModel model,
                                                int row)
        Factory method to create and initialize a row object.
        Parameters:
        model - the model required to gather data for the row object.
        row - the row for which to create a row object * @return
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object