INotifyCollectionChangedSynchronizedViewList To NotifyCollectionChangedSynchronizedViewList

This commit is contained in:
zerodev1200 2024-10-17 23:07:51 +09:00
parent 8913192459
commit 290b455c47
2 changed files with 8 additions and 8 deletions

View File

@ -176,22 +176,22 @@ namespace ObservableCollections
return new NonFilteredSynchronizedViewList<T, TView>(collection.CreateView(transform), isSupportRangeFeature: true, null, null); return new NonFilteredSynchronizedViewList<T, TView>(collection.CreateView(transform), isSupportRangeFeature: true, null, null);
} }
public static INotifyCollectionChangedSynchronizedViewList<T> ToNotifyCollectionChanged<T>(this IObservableCollection<T> collection) public static NotifyCollectionChangedSynchronizedViewList<T> ToNotifyCollectionChanged<T>(this IObservableCollection<T> collection)
{ {
return ToNotifyCollectionChanged(collection, null); return ToNotifyCollectionChanged(collection, null);
} }
public static INotifyCollectionChangedSynchronizedViewList<T> ToNotifyCollectionChanged<T>(this IObservableCollection<T> collection, ICollectionEventDispatcher? collectionEventDispatcher) public static NotifyCollectionChangedSynchronizedViewList<T> ToNotifyCollectionChanged<T>(this IObservableCollection<T> collection, ICollectionEventDispatcher? collectionEventDispatcher)
{ {
return ToNotifyCollectionChanged(collection, static x => x, collectionEventDispatcher); return ToNotifyCollectionChanged(collection, static x => x, collectionEventDispatcher);
} }
public static INotifyCollectionChangedSynchronizedViewList<TView> ToNotifyCollectionChanged<T, TView>(this IObservableCollection<T> collection, Func<T, TView> transform) public static NotifyCollectionChangedSynchronizedViewList<TView> ToNotifyCollectionChanged<T, TView>(this IObservableCollection<T> collection, Func<T, TView> transform)
{ {
return ToNotifyCollectionChanged(collection, transform, null!); return ToNotifyCollectionChanged(collection, transform, null!);
} }
public static INotifyCollectionChangedSynchronizedViewList<TView> ToNotifyCollectionChanged<T, TView>(this IObservableCollection<T> collection, Func<T, TView> transform, ICollectionEventDispatcher? collectionEventDispatcher) public static NotifyCollectionChangedSynchronizedViewList<TView> ToNotifyCollectionChanged<T, TView>(this IObservableCollection<T> collection, Func<T, TView> transform, ICollectionEventDispatcher? collectionEventDispatcher)
{ {
// Optimized for non filtered // Optimized for non filtered
return new NonFilteredSynchronizedViewList<T, TView>(collection.CreateView(transform), isSupportRangeFeature: false, collectionEventDispatcher, null); return new NonFilteredSynchronizedViewList<T, TView>(collection.CreateView(transform), isSupportRangeFeature: false, collectionEventDispatcher, null);

View File

@ -19,12 +19,12 @@ namespace ObservableCollections
return new View<TView>(this, transform); return new View<TView>(this, transform);
} }
public INotifyCollectionChangedSynchronizedViewList<T> ToWritableNotifyCollectionChanged() public NotifyCollectionChangedSynchronizedViewList<T> ToWritableNotifyCollectionChanged()
{ {
return ToWritableNotifyCollectionChanged(null); return ToWritableNotifyCollectionChanged(null);
} }
public INotifyCollectionChangedSynchronizedViewList<T> ToWritableNotifyCollectionChanged(ICollectionEventDispatcher? collectionEventDispatcher) public NotifyCollectionChangedSynchronizedViewList<T> ToWritableNotifyCollectionChanged(ICollectionEventDispatcher? collectionEventDispatcher)
{ {
return ToWritableNotifyCollectionChanged( return ToWritableNotifyCollectionChanged(
static x => x, static x => x,
@ -36,12 +36,12 @@ namespace ObservableCollections
collectionEventDispatcher); collectionEventDispatcher);
} }
public INotifyCollectionChangedSynchronizedViewList<TView> ToWritableNotifyCollectionChanged<TView>(Func<T, TView> transform, WritableViewChangedEventHandler<T, TView>? converter) public NotifyCollectionChangedSynchronizedViewList<TView> ToWritableNotifyCollectionChanged<TView>(Func<T, TView> transform, WritableViewChangedEventHandler<T, TView>? converter)
{ {
return ToWritableNotifyCollectionChanged(transform, converter, null!); return ToWritableNotifyCollectionChanged(transform, converter, null!);
} }
public INotifyCollectionChangedSynchronizedViewList<TView> ToWritableNotifyCollectionChanged<TView>(Func<T, TView> transform, WritableViewChangedEventHandler<T, TView>? converter, ICollectionEventDispatcher? collectionEventDispatcher) public NotifyCollectionChangedSynchronizedViewList<TView> ToWritableNotifyCollectionChanged<TView>(Func<T, TView> transform, WritableViewChangedEventHandler<T, TView>? converter, ICollectionEventDispatcher? collectionEventDispatcher)
{ {
return new NonFilteredSynchronizedViewList<T, TView>(CreateView(transform), isSupportRangeFeature: false, collectionEventDispatcher, converter); return new NonFilteredSynchronizedViewList<T, TView>(CreateView(transform), isSupportRangeFeature: false, collectionEventDispatcher, converter);
} }