using System.Collections.ObjectModel; using System.Runtime.InteropServices.WindowsRuntime; using System.Threading.Tasks; using Windows.Foundation; using Windows.UI.Xaml.Data; namespace FoxTube.Models.Collections { public abstract class ViewCollection : ObservableCollection, ISupportIncrementalLoading { public int ItemsPerRequest { get; set; } public bool HasMoreItems { get; protected set; } = true; public IAsyncOperation LoadMoreItemsAsync(uint count) => AsyncInfo.Run((c) => LoadItems()); public abstract Task LoadItems(); } }