Menu

#55 configurable RowSorter

open
7
2012-10-08
2004-05-23
No

(from displaytag-devel)

Hi,

I want to use a decorator and sort a full list without
having to decorate the entire list. I don't see a way
to do it. This is way too slow for my purposes.

I've implemented by own Sorter but you've declared a
crucial method in the RowSorter final, so simple
extension won't work and I don't see a way to plug it
in without using a heavily modified version of
displaytag.

You should be able to plugin any Sorter that
implements a basic interface, just like the decorator.
TabelModel only uses RowSorter. RowSorter should
implement a RowSorter interface. . . .

If I missed something, please let me know. I might
not be familiar with some new features.

Thanks,

Aaron Smuts

Discussion

  • fabrizio giustina

    Logged In: YES
    user_id=798060

    makes sense, I'll check it while investigating the "sort using
    property" enhancement

     
  • Nobody/Anonymous

    Logged In: NO

    Another benefit in implementing a custom rowsorter is that
    you can avoid reflection on sorts. You can create a sorter
    for a particular type of object and speed things up.

    I'll post an interface and the simple get class by name section
    to be put in during the intantiation of the sorter. Also, the
    existing sorter should just implment the interface. It's fairly
    simple.

     

Log in to post a comment.