Modifyable Filter Conditions

Feb 25, 2008 at 6:44 PM
It would be nice if there was some way to adjust the filter conditions and allow the entire underlying set to have its inclusion in the result set reevaluated. This would require modifications to the FilteringViewAdapter. It could be as simple as some way to notify from the base collection that a variable used by the filtering condition function has been updated, so please rerun the function over all underlying items.

Let me know if this is possible, and if it is something you are planning on doing already.

Regards,

-Karl
Coordinator
Feb 25, 2008 at 7:01 PM


krs43 wrote:
It would be nice if there was some way to adjust the filter conditions and allow the entire underlying set to have its inclusion in the result set reevaluated. This would require modifications to the FilteringViewAdapter. It could be as simple as some way to notify from the base collection that a variable used by the filtering condition function has been updated, so please rerun the function over all underlying items.

Let me know if this is possible, and if it is something you are planning on doing already.

Regards,

-Karl


This is definitely something that I've thought about doing, just haven't gotten around to it. I tried to hit the largest, most frequently used use case scenarios with the LINQ operators. Now that those are done, once I (or the others working on the project) get some free time, adding support for this kind of thing as well as continuous aggregation are on my priority list.
Feb 25, 2008 at 11:06 PM
Thanks for the update, let me know if there is anyway I can contribute (I posted my mods for the orderby filter under Issue Tracker). If you have a starting point, let me know, otherwise I will atleast make a quick change to allow for refreshing so that I can use this in my current program.

Thanks,

-Karl
Coordinator
Apr 17, 2008 at 6:09 PM


krs43 wrote:
Thanks for the update, let me know if there is anyway I can contribute (I posted my mods for the orderby filter under Issue Tracker). If you have a starting point, let me know, otherwise I will atleast make a quick change to allow for refreshing so that I can use this in my current program.

Thanks,

-Karl


Have you tried using the ReEvaluate() method after modifying the contents of the filter? This should re-evaluate the conditions in your filter function and cascade that out through your CLINQ query. I don't think ReEvaluate() is in 1.0, you'll have to grab the 1.1 source until we get the 1.1 release build out.

You would invoke it like this:

myContinuousCollection.SourceAdapter.ReEvaluate();
Aug 2, 2010 at 6:15 PM
Edited Aug 2, 2010 at 6:16 PM
Hi,
First of all: AWESOME job on CLINQ! Love it.

Question: I cannot find ReEvaluate in 2.x. Did you remove this?
Is there a smarter way to have the filters update if the parameters change?

Here is a simple code sample
// First filter Task.Title
_listFiltered1 = from item in _mainList
where item.Title.Contains(SearchText)
select item;

// Then filter Task.Tag (notice we base it on the result of the first search)
_listFiltered2 = from item in _listFiltered1
where item.Tag.Contains(SearchText2)
select item;

When I change either SearchText or SearchText2, I would like the filters to reevaluate.

Thanks!