Interface SortableTable

    • Method Detail

      • setUnsortedModel

        void setUnsortedModel​(TableModel value)
        Sets the base model to use.
        Parameters:
        value - the base model
      • getUnsortedModel

        TableModel getUnsortedModel()
        returns the underlying model, can be null.
        Returns:
        the current model
      • isSorted

        boolean isSorted()
        returns whether the table was sorted.
        Returns:
        true if the table was sorted
      • getSortColumn

        int getSortColumn()
        Returns the sort column.
        Returns:
        the sort column
      • isAscending

        boolean isAscending()
        Returns whether sorting is ascending or not.
        Returns:
        true if ascending
        See Also:
        isSorted(), getSortColumn()
      • sort

        void sort​(int columnIndex)
        sorts the table over the given column (ascending).
        Parameters:
        columnIndex - the column to sort over
      • sort

        void sort​(int columnIndex,
                  boolean ascending)
        sorts the table over the given column, either ascending or descending.
        Parameters:
        columnIndex - the column to sort over
        ascending - ascending if true, otherwise descending