using System.Collections.ObjectModel;
using AyCode.Core.Interfaces;
using AyCode.Services.Server.SignalRs;
using AyCode.Services.SignalRs;
using System.Diagnostics;
using AyCode.Core.Helpers;

namespace FruitBankHybrid.Shared.Services.SignalRs;

[Serializable]
[DebuggerDisplay("Count = {Count}")]
public class SignalRDataSourceList<TDataItem>(AcSignalRClientBase signalRClient, SignalRCrudTags signalRCrudTags, params object[]? contextIds)
    : AcSignalRDataSource<TDataItem, int, List<TDataItem>>(signalRClient, signalRCrudTags, contextIds) where TDataItem : class, IId<int>;

[Serializable]
[DebuggerDisplay("Count = {Count}")]
public class SignalRDataSourceObservable<TDataItem>(AcSignalRClientBase signalRClient, SignalRCrudTags signalRCrudTags, params object[]? contextIds)
    : AcSignalRDataSource<TDataItem, int, AcObservableCollection<TDataItem>>(signalRClient, signalRCrudTags, contextIds) where TDataItem : class, IId<int>;