Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » NatTable » Adding filter to entire table like viewer filters in TreeViewer(How to achive filtering on the entire table instead of filtering by column)
Adding filter to entire table like viewer filters in TreeViewer [message #1264692] Wed, 05 March 2014 12:24 Go to next message
kiran kumar is currently offline kiran kumarFriend
Messages: 2
Registered: March 2014
Junior Member
Hi,

I am trying to add a filter to the entire table similar to Viewers{i.e. by using ViewerFilter}.I went through all the examples and the NatTable forum, looking for examples related to filtering but I could only find information related to column filters.
Could you please suggest how I can achieve this in NatTable?

Regards,
KiranKumar H.V
Re: Adding filter to entire table like viewer filters in TreeViewer [message #1264796 is a reply to message #1264692] Wed, 05 March 2014 14:08 Go to previous messageGo to next message
Dirk Fauth is currently offline Dirk FauthFriend
Messages: 2902
Registered: July 2012
Senior Member
Sorry I don't understand your requirement. What do you mean with "add a filter to the entire table"? If there should be only one field that performs a filter operation you will need to create an external control and apply a filter. Within NatTable you could try to create a cell that spans all other cells. Not sure if that breaks any other use case for huge data sets.

If you just need to set a filter in the background instead of having a filter row, than you should look either on how to filter with a FilterList in GlazedLists (if you are using GlazedLists) or as an alternative have a look at AbstractFilterListDataProvider. Although I suggest to use the FilterList approach, because the AbstractFilterListDataProvider is not the best when it comes to performance. So for huge datasets it will be a mess.
Re: Adding filter to entire table like viewer filters in TreeViewer [message #1266383 is a reply to message #1264796] Fri, 07 March 2014 11:23 Go to previous message
kiran kumar is currently offline kiran kumarFriend
Messages: 2
Registered: March 2014
Junior Member
Thanks for the quick reply dirk,

Yes i wanted to have a filters like Treeviewer.addFilter(new ViewerFIlter());
during refresh these filters were apllied in normal viewers.
I wanted to contribute a feature similar to these in natTable so that i can plug any filters at runtime.

As you said, i looked in to FilterList and implemented my own filter stratergy for filtering. It worked. Smile Smile
Now i have to make it somewhat generic so that i can add as many filters for background Processing Smile


Regards,
Kiran
Previous Topic:Summary layer with group by layer
Next Topic:NPE in SelectionModel
Goto Forum:
  


Current Time: Thu Apr 25 08:31:33 GMT 2024

Powered by FUDForum. Page generated in 0.04183 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top