TableSorter slow?
Hello
Let me begin by saying I am a novice, and I appreciate very much SUN's extra effort in making classes like TableSort publicy available. However, I have a JTable that use TableSort, and I find it very slow in sorting. Since I do not understand all code (in partucular those regarding listeners) in TableSort, I am unsure whether it is my implementation of TableModel that is causing this, or TableSort itself.
My JTable is moderately large: it has ~400 000 lines. The program paints the JTable quckly enough, but sorting a column takes a long while (I loose patience after 10 min..).
My TableModel is infact a TreeModel that implements TableModel, and as such I suspect the getValueAt() methods may not be super-efficient. However, do you believe the slow sort is a result of such a TableModel? Or do you believe it is simply too much data to sort effective?
I have an idea for increasing sort speed. My table is not editable (no inserts or deletion or celledits allowed), so any sorting would only constitute in a reverse order of the view index (or is it model index?), alternative using original index. But, alas I am not capable enough to make these changes in the TableSort code.
I know that sorting an Array of data is much much faster.
Your experience or comment is appreciated.
Regard
Fluid

