You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A Grouping operator that supports the Group Key Selector changing dynamically, such as:
IObservable<IGroupChangeSet<TObject,TKey,TGroupKey>>Group(thisIObservable<IChangeSet<TObject,TKey>>source,IObservable<Func<TObject,TKey,TGroupKey>>grouperObservable);// Also maybeIObservable<IGroupChangeSet<TObject,TKey,TGroupKey>>Group(thisIObservable<IChangeSet<TObject,TKey>>source,IObservable<Func<TObject,TKey,TGroupKey>>grouperObservable,IObservable<Unit>regrouper);
The steps the functionality will provide
When groupObservable fires, it will regroup all the items according to the new Grouping Key selector function.
If regrouper is provided, it will re-evaluate the grouping using the current Grouping Key.
Considerations
Current Group operators don't support changing of the Group Key selector. The Group Key selector can be dynamically re-applied, but it can't be changed.
GroupOnObservable allows for dynamic changing of the Group Key Value but on a per item basis.
The text was updated successfully, but these errors were encountered:
dwcullop
changed the title
[Feature]: Group Operator that supports Dynamic Group Selection
[Feature]: Group Operator with a Dynamic Grouping Key Selector
Feb 10, 2024
Addresses #848 by providing new overloads for the `Group` operator that allow the user to supply a `IObservable<Func<TObject, TKey, TGroupKey>>` so that the function that is used to obtain the GroupKey can change dynamically. When a new value is supplied, a new GroupKey will be obtained for each item, and if the GroupKey has changed, the item will be moved to the new Group.
Also allows for an optional `IObservable<Unit>` parameter that will force the current GroupKey selector to be re-applied to all the items.
Describe the functionality desired
A Grouping operator that supports the Group Key Selector changing dynamically, such as:
The steps the functionality will provide
When
groupObservable
fires, it will regroup all the items according to the new Grouping Key selector function.If
regrouper
is provided, it will re-evaluate the grouping using the current Grouping Key.Considerations
Current Group operators don't support changing of the Group Key selector. The Group Key selector can be dynamically re-applied, but it can't be changed.
GroupOnObservable
allows for dynamic changing of the Group Key Value but on a per item basis.The text was updated successfully, but these errors were encountered: