add overload WritableFiltable ToWritableNotifyCollectionChanged()
This commit is contained in:
parent
290b455c47
commit
367be8717c
@ -58,6 +58,7 @@ namespace ObservableCollections
|
||||
void SetToSourceCollection(int index, T value);
|
||||
void AddToSourceCollection(T value);
|
||||
IWritableSynchronizedViewList<TView> ToWritableViewList(WritableViewChangedEventHandler<T, TView> converter);
|
||||
NotifyCollectionChangedSynchronizedViewList<TView> ToWritableNotifyCollectionChanged();
|
||||
NotifyCollectionChangedSynchronizedViewList<TView> ToWritableNotifyCollectionChanged(WritableViewChangedEventHandler<T, TView> converter);
|
||||
NotifyCollectionChangedSynchronizedViewList<TView> ToWritableNotifyCollectionChanged(ICollectionEventDispatcher? collectionEventDispatcher);
|
||||
NotifyCollectionChangedSynchronizedViewList<TView> ToWritableNotifyCollectionChanged(WritableViewChangedEventHandler<T, TView> converter, ICollectionEventDispatcher? collectionEventDispatcher);
|
||||
|
@ -373,6 +373,17 @@ namespace ObservableCollections
|
||||
return new FiltableSynchronizedViewList<T, TView>(this, isSupportRangeFeature: true, converter: converter);
|
||||
}
|
||||
|
||||
public NotifyCollectionChangedSynchronizedViewList<TView> ToWritableNotifyCollectionChanged()
|
||||
{
|
||||
return new FiltableSynchronizedViewList<T, TView>(this,
|
||||
isSupportRangeFeature: false,
|
||||
converter: static (TView newView, T originalValue, ref bool setValue) =>
|
||||
{
|
||||
setValue = true;
|
||||
return originalValue;
|
||||
});
|
||||
}
|
||||
|
||||
public NotifyCollectionChangedSynchronizedViewList<TView> ToWritableNotifyCollectionChanged(WritableViewChangedEventHandler<T, TView> converter)
|
||||
{
|
||||
return new FiltableSynchronizedViewList<T, TView>(this, isSupportRangeFeature: false, converter: converter);
|
||||
|
Loading…
x
Reference in New Issue
Block a user