Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » NatTable » Contribution in Nattable Builder ?
Contribution in Nattable Builder ? [message #1063423] Thu, 13 June 2013 03:12 Go to next message
SD Khan is currently offline SD Khan
Messages: 63
Registered: May 2013
Member
Hi,

I want's to contribute in nattable builder api, i have created a defect and submitted it on bugzilla along with it' solution, but it's status is still "UnConfirmed", so who will be looking into this and will verify changes for nattabuilder api ?,

i want's to propose more defects and suggestions, as i am using this api in my application, so with the time i am adding enhancements and fixing the defects for my application, now i want's to contribute it back so that every one in the open source community can get the advantage, so how it should be done ?

Regards,
Safdar Khan
Re: Contribution in Nattable Builder ? [message #1063439 is a reply to message #1063423] Thu, 13 June 2013 03:52 Go to previous messageGo to next message
Dirk Fauth is currently offline Dirk Fauth
Messages: 1255
Registered: July 2012
Senior Member
Hi,

although I don't have much time to look at the builder stuff, I looked into your contribution. And to be honest, I don't understand what your are trying to do!

In the bug report you are saying that you are implementing your own IFilterStrategy and then complain that the DefaultGlazedListsFilterStrategy has a different MatcherEditor. That doesn't make sense! Either you want to use your own IFilterStrategy or the DefaultGlazedListsFilterStrategy. Using both in parallel shouldn't work.

As far as I can see, the builder api does not support custom IFilterStrategy usage, so you need to extend it at that place, not extending the DefaultGlazedListsFilterStrategy to do stuff that is not intended like setting the MatcherEditor afterwards.

Greez,
Dirk
Re: Contribution in Nattable Builder ? [message #1063457 is a reply to message #1063439] Thu, 13 June 2013 04:39 Go to previous messageGo to next message
SD Khan is currently offline SD Khan
Messages: 63
Registered: May 2013
Member
Thanks for your reply, Just for getting on conclusion plz read the post,

My concept is whenever we need to use filtering two things must be done.

1. filterList.setMatcherEditor(matcherEditor)
2. set the same matcher editor while creating glazed list filter strategy object.


Is it right? please correct , if i am wrong.

Now when, i am using "enable filter row", builder api perform the above two steps and it works fine,

Now i am filtering rows on some fix criteria and implemented IFilterStrategy and performing filtering mechanism for that. performed the above two steps.

Now what? ,

When i have performed the above two steps, matcherEditor object that FilterList holds, get changed, while "DefaultGlazedListFilterStrategy" has the old object which was assigned to it at the time of enabling that switch.

So, "enable filter row", stopped performing filtering due to different object of matcher editor in filterlist and filterstrategy,

As a result i have suggested the set method for matcher editor in filter strategy so that it can be set at any time and synchronized with FilterList,

As you rejected this, it seems i can't use the "enable filter row" functionality with my custom filtering any more Sad ,?

Regards,
SD K
Re: Contribution in Nattable Builder ? [message #1063462 is a reply to message #1063457] Thu, 13 June 2013 04:51 Go to previous messageGo to next message
Dirk Fauth is currently offline Dirk Fauth
Messages: 1255
Registered: July 2012
Senior Member
1. Yes the FilterList and the DefaultGlazedListsFilterStrategy need to operate on the same MatcherEditor. It performs the filtering on the FilterList and gets the data for filtering out of the DefaultGlazedListsFilterStrategy.

2. You want to filter ADDITIONALLY to the filter row by some fixed criteria. As I told you in the previous posts, you should think about using the DefaultGlazedListsStaticFilterStrategy which does exactly that. There you can ADD additional matchers by still having the filter row working.

This means you
a) need to adjust the builder api to use the DefaultGlazedListsStaticFilterStrategy instead of the DefaultGlazedListsFilterStrategy, which is also backwards compatible
b) change your IFilterStrategy to a custom Matcher or MatcherEditor that you add to (and possibly remove again from) the DefaultGlazedListsStaticFilterStrategy

Doing this you are able to use "enable filter row" with your custom filtering. And it is much easier and does not change API.

Greez,
Dirk
Re: Contribution in Nattable Builder ? [message #1063584 is a reply to message #1063462] Thu, 13 June 2013 09:04 Go to previous message
SD Khan is currently offline SD Khan
Messages: 63
Registered: May 2013
Member
Yup, it looks gud, i try that,

Thanks,
Safdar Khan
Previous Topic:Font changes when editing a cell with an Inline Text Control
Next Topic:Synchronise two NatTables when scrolling and row resizing.
Goto Forum:
  


Current Time: Thu Aug 21 22:15:48 EDT 2014

Powered by FUDForum. Page generated in 0.02424 seconds