menu

Xamarin.Android

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class PagedCollectionView - Xamarin.Android API Reference | Syncfusion

    Show / Hide Table of Contents

    Class PagedCollectionView

    Inheritance
    System.Object
    CollectionViewAdv
    QueryableCollectionView
    PagedCollectionView
    Implements
    ICollectionViewAdv
    System.Collections.IEnumerable
    System.Collections.Specialized.INotifyCollectionChanged
    System.ComponentModel.INotifyPropertyChanged
    ISupportInitialize
    System.IDisposable
    IPropertyChangedEventHandler
    IEditableCollectionView
    ISupportIncrementalLoading
    IUnboundExpressionFunc
    IGridViewNotifier
    IFilterExt
    IParallelizableView
    Inherited Members
    CollectionViewAdv.Add(Object)
    CollectionViewAdv.add_CurrentChanging(CurrentChangingEventHandler)
    CollectionViewAdv.AddNew()
    CollectionViewAdv.AddNotifyListener(Object)
    CollectionViewAdv.AttachGridView(Object)
    CollectionViewAdv.AutoExpandGroups
    CollectionViewAdv.BeginInit(Boolean)
    CollectionViewAdv.CanCancelEdit
    CollectionViewAdv.CancelEdit()
    CollectionViewAdv.CancelNew()
    CollectionViewAdv.CanFilter
    CollectionViewAdv.CanGroup
    CollectionViewAdv.CanListenNotifiers
    CollectionViewAdv.CanRemove
    CollectionViewAdv.CanSort
    CollectionViewAdv.CanUpdateSummary(ISummaryRow, String)
    CollectionViewAdv.CaptionSummaryRow
    CollectionViewAdv.Clear()
    CollectionViewAdv.CollectionChanged
    CollectionViewAdv.CommitNew()
    CollectionViewAdv.Contains(Object)
    CollectionViewAdv.CopyTo(Object[], Int32)
    CollectionViewAdv.Count
    CollectionViewAdv.CreateItemPropertiesProvider()
    CollectionViewAdv.CreateRecordEntry(Object)
    CollectionViewAdv.CreateTopLevelGroup()
    CollectionViewAdv.Culture
    CollectionViewAdv.CurrentAddItem
    CollectionViewAdv.CurrentChanged
    CollectionViewAdv.CurrentChanging
    CollectionViewAdv.CurrentEditItem
    CollectionViewAdv.currentItem
    CollectionViewAdv.CurrentItem
    CollectionViewAdv.currentPosition
    CollectionViewAdv.CurrentPosition
    CollectionViewAdv.DeferRefresh()
    CollectionViewAdv.DeferRefresh(Boolean)
    CollectionViewAdv.DetachGridView()
    CollectionViewAdv.Dispose()
    CollectionViewAdv.Dispose(Boolean)
    CollectionViewAdv.editItem
    CollectionViewAdv.EditItem(Object)
    CollectionViewAdv.EndEdit()
    CollectionViewAdv.EndInit()
    CollectionViewAdv.EnsureInitialized()
    CollectionViewAdv.EnsureSourceList()
    CollectionViewAdv.FetchSize
    CollectionViewAdv.Filter
    CollectionViewAdv.GetActiveComparer()
    CollectionViewAdv.GetDataGrid()
    CollectionViewAdv.GetDisplayValueExpressionFunc(String, DataOperation)
    CollectionViewAdv.GetDisplayValueFunc(String, DataOperation)
    CollectionViewAdv.GetEnumerator()
    CollectionViewAdv.GetExpressionFunc(String, DataOperation, DataReflectionMode)
    CollectionViewAdv.GetFunc(String, DataOperation, DataReflectionMode)
    CollectionViewAdv.GetGroupConverterFunc(String)
    CollectionViewAdv.GetItemAt(Int32)
    CollectionViewAdv.GetItemProperties()
    CollectionViewAdv.GetPropertyAccessProvider()
    CollectionViewAdv.GetRecordAt(Int32)
    CollectionViewAdv.GetSource()
    CollectionViewAdv.GetSourceListCollection()
    CollectionViewAdv.GroupComparer
    CollectionViewAdv.GroupDescriptions
    CollectionViewAdv.GroupList
    CollectionViewAdv.Groups
    CollectionViewAdv.HasMoreItems
    CollectionViewAdv.IndexOf(Object)
    CollectionViewAdv.InitiateCollectionViewAdv()
    CollectionViewAdv.Insert(Int32, Object)
    CollectionViewAdv.IsAddingNew
    CollectionViewAdv.IsCurrentAfterLast
    CollectionViewAdv.IsCurrentBeforeFirst
    CollectionViewAdv.IsDisposed
    CollectionViewAdv.IsDynamicBound
    CollectionViewAdv.IsEditingItem
    CollectionViewAdv.IsEmpty
    CollectionViewAdv.IsGrouping
    CollectionViewAdv.IsInCommitEdit
    CollectionViewAdv.IsInCommitNew
    CollectionViewAdv.IsInDeferRefresh
    CollectionViewAdv.IsInEndDeferral
    CollectionViewAdv.IsInGroup
    CollectionViewAdv.IsInPropertyChange
    CollectionViewAdv.IsInSourceCollectionChange
    CollectionViewAdv.IsInSuspend
    CollectionViewAdv.IsIQueryable
    CollectionViewAdv.IsItemPropertiesTypeSet
    CollectionViewAdv.IsLegacyDataTable
    CollectionViewAdv.IsReadOnly
    CollectionViewAdv.IsXElementBound
    CollectionViewAdv.Item[Int32]
    CollectionViewAdv.ItemProperties
    CollectionViewAdv.ItemPropertiesSet
    CollectionViewAdv.KeyValue
    CollectionViewAdv.LiveDataUpdateMode
    CollectionViewAdv.LoadMoreItemsAsync(UInt32)
    CollectionViewAdv.MoveCurrentTo(Object)
    CollectionViewAdv.MoveCurrentToFirst()
    CollectionViewAdv.MoveCurrentToLast()
    CollectionViewAdv.MoveCurrentToNext()
    CollectionViewAdv.MoveCurrentToPosition(Int32)
    CollectionViewAdv.MoveCurrentToPrevious()
    CollectionViewAdv.NewItemPlaceholderPosition
    CollectionViewAdv.NotificationSubscriptionMode
    CollectionViewAdv.OnCollectionChanged(NotifyCollectionChangedEventArgs)
    CollectionViewAdv.OnPropertyChanged(Object, PropertyChangedEventArgs)
    CollectionViewAdv.OnRecordCollectionChanged(Object, NotifyCollectionChangedEventArgs)
    CollectionViewAdv.OnRecordPropertyChanged(Object, PropertyChangedEventArgs)
    CollectionViewAdv.OnTopLevelGroupCollectionChanged(Object, NotifyCollectionChangedEventArgs)
    CollectionViewAdv.OnTopLevelGroupPopulated(TopLevelGroup)
    CollectionViewAdv.propertyAccessProvider
    CollectionViewAdv.PropertyChanged
    CollectionViewAdv.RaiseCollectionChangedEvent(NotifyCollectionChangedEventArgs)
    CollectionViewAdv.RaiseCurrentChangedEvent()
    CollectionViewAdv.RaiseCurrentChangingEvent()
    CollectionViewAdv.RaiseExceptionThrownEvent(Exception)
    CollectionViewAdv.RaiseGroupCollectionChanged(NotifyGroupsChangedEventArgs)
    CollectionViewAdv.RaisePropertyChanged(String)
    CollectionViewAdv.RaiseSourceCollectionChangedEvent(NotifyCollectionChangedEventArgs)
    CollectionViewAdv.RecordPropertyChanged
    CollectionViewAdv.Records
    CollectionViewAdv.Refresh()
    CollectionViewAdv.RefreshTopLevelGroup()
    CollectionViewAdv.RefreshView(NotifyCollectionChangedEventArgs)
    CollectionViewAdv.remove_CurrentChanging(CurrentChangingEventHandler)
    CollectionViewAdv.RemoveAt(Int32)
    CollectionViewAdv.RemoveNotifyListener(Object)
    CollectionViewAdv.RemoveRecord(Object)
    CollectionViewAdv.SetActiveComparer()
    CollectionViewAdv.SetCurrent(Object, Int32)
    CollectionViewAdv.SetCurrent(Object, Int32, Int32)
    CollectionViewAdv.SetFlag(CollectionViewAdv.CollectionViewFlags, Boolean)
    CollectionViewAdv.SetItemProperties(IEnumerable)
    CollectionViewAdv.SetSourceType(Type)
    CollectionViewAdv.SortComparers
    CollectionViewAdv.SortDescriptions
    CollectionViewAdv.SourceCollection
    CollectionViewAdv.SourceCollectionChanged
    CollectionViewAdv.SourceListChanged(Object, ListChangedEventArgs)
    CollectionViewAdv.SourceType
    CollectionViewAdv.SummaryCalculationMode
    CollectionViewAdv.SummaryRows
    CollectionViewAdv.TableSummaryRows
    CollectionViewAdv.TopLevelGroup
    CollectionViewAdv.TopLevelGroupCollectionChanged
    CollectionViewAdv.UnWireEvents()
    QueryableCollectionView.CanExecuteParallel(DataOperation)
    QueryableCollectionView.CreateRowFilterPredicate()
    QueryableCollectionView.FilterRecord(Object)
    QueryableCollectionView.GetPredicateExpression(IQueryable, ParameterExpression)
    QueryableCollectionView.GetPredicateExpression(IQueryable, ParameterExpression, String, Boolean)
    QueryableCollectionView.OnSortDescriptionChanged(NotifyCollectionChangedEventArgs)
    QueryableCollectionView.RefreshSortingOrderWithFiltersForBottomLevel(List<Group>)
    QueryableCollectionView.ResetFilter()
    QueryableCollectionView.RowFilter
    QueryableCollectionView.SortQueryable(IQueryable, SortDescriptionCollection)
    QueryableCollectionView.UsePLINQ
    QueryableCollectionView.ViewSource
    Namespace: Syncfusion.Data
    Assembly: Syncfusion.Data.Portable.dll
    Syntax
    public class PagedCollectionView : QueryableCollectionView, ICollectionViewAdv, ICollectionView, IEnumerable, INotifyCollectionChanged, INotifyPropertyChanged, ISupportInitialize, IDisposable, IPropertyChangedEventHandler, IEditableCollectionView, ISupportIncrementalLoading, IUnboundExpressionFunc, IGridViewNotifier, IFilterExt, IParallelizableView, IPagedCollectionView

    Constructors

    PagedCollectionView()

    Initializes a new instance of the PagedCollectionView class.

    Declaration
    public PagedCollectionView()

    PagedCollectionView(IEnumerable)

    Initializes a new instance of the PagedCollectionView class.

    Declaration
    public PagedCollectionView(IEnumerable source)
    Parameters
    Type Name Description
    System.Collections.IEnumerable source

    The IEnumerable source of the SfDataGrid.

    Fields

    OnDemandPageCache

    Gets the on demand paged cache which contains the cache of the records in the previous page.

    Declaration
    protected Dictionary<int, IEnumerable> OnDemandPageCache
    Field Value
    Type
    System.Collections.Generic.Dictionary<System.Int32, System.Collections.IEnumerable>

    Properties

    CanAddNew

    Gets a value that indicates whether a new item can be added to the collection.

    Declaration
    public override bool CanAddNew { get; }
    Property Value
    Type Description
    System.Boolean

    True if a new item can be added to the collection, otherwisefalse.

    Overrides
    CollectionViewAdv.CanAddNew

    EnableSummaryOptimization

    Gets or sets a boolean value that indicates whether to enable optimistic summary calculation on real time updates.

    Declaration
    public override bool EnableSummaryOptimization { get; }
    Property Value
    Type Description
    System.Boolean

    A boolean value that indicates whether to enable optimistic summary calculation on real time updates.

    Overrides
    CollectionViewAdv.EnableSummaryOptimization
    Remarks

    The calculates the summary optimistically when the data objects implement the System.ComponentModel.INotifyPropertyChanging and System.ComponentModel.INotifyPropertyChanged.

    FilterPredicates

    Gets or sets the collection of FilterPredicates, based on which filtering is performed in the underlying collection.

    Declaration
    public override ObservableCollection<IFilterDefinition> FilterPredicates { get; set; }
    Property Value
    Type Description
    System.Collections.ObjectModel.ObservableCollection<IFilterDefinition>

    The collection of FilterPredicates, based on which filtering is performed in the underlying collection.

    Overrides
    CollectionViewAdv.FilterPredicates

    ItemCount

    Gets the number of items in the collection view.

    Declaration
    public int ItemCount { get; }
    Property Value
    Type Description
    System.Int32

    The number of items in the collection view.

    MaxItemsCount

    Gets or sets the maximum items count in the paged collection view.

    Declaration
    public int MaxItemsCount { get; set; }
    Property Value
    Type Description
    System.Int32

    The maximum items count in the paged collection view.

    PageCount

    Gets the number of pages in the paged collection view.

    Declaration
    public virtual int PageCount { get; }
    Property Value
    Type Description
    System.Int32

    The number of pages in the paged collection view.

    PageIndex

    Gets the page index of the current page.

    Declaration
    public int PageIndex { get; }
    Property Value
    Type Description
    System.Int32

    The page index of the current page.

    PageSize

    Gets or sets the page size, which indicates the number of rows to be displayed in the page.

    Declaration
    public int PageSize { get; set; }
    Property Value
    Type Description
    System.Int32

    The page size, which indicates the number of rows to be displayed in the page.

    TotalItemCount

    Gets the total items count in the collection view.

    Declaration
    public int TotalItemCount { get; }
    Property Value
    Type Description
    System.Int32

    The total items count in the collection view.

    UseOnDemandPaging

    Gets or sets a boolean value indicating whether to use on demand paging, when on demand paging is enabled the items will be populated to the page only when navigated to the page.

    Declaration
    public bool UseOnDemandPaging { get; set; }
    Property Value
    Type Description
    System.Boolean

    A boolean value indicating whether to use on demand paging.

    Methods

    add_OnDemandItemsLoading(OnDemandItemsLoadingEventHandler)

    Declaration
    public void add_OnDemandItemsLoading(OnDemandItemsLoadingEventHandler value)
    Parameters
    Type Name Description
    OnDemandItemsLoadingEventHandler value

    add_PageChanged(PageChangedEventHandler)

    Declaration
    public void add_PageChanged(PageChangedEventHandler value)
    Parameters
    Type Name Description
    PageChangedEventHandler value

    add_PageChanging(PageChangingEventHandler)

    Declaration
    public void add_PageChanging(PageChangingEventHandler value)
    Parameters
    Type Name Description
    PageChangingEventHandler value

    AdjustBeforeAdd(Object, Int32)

    Adjust the underlying collection by getting the comparer index before adding the given record at the given index in the view.

    Declaration
    protected override int AdjustBeforeAdd(object record, int index)
    Parameters
    Type Name Description
    System.Object record

    The record to be added to the collection.

    System.Int32 index

    The index at which the record is to be added.

    Returns
    Type Description
    System.Int32

    Gets the comparer index based on the given index and records in the collection.

    Overrides
    CollectionViewAdv.AdjustBeforeAdd(Object, Int32)

    CommitEdit()

    Ends the edit transaction and saves the pending changes.

    Declaration
    public override void CommitEdit()
    Overrides
    CollectionViewAdv.CommitEdit()

    CreateRecords()

    Creates the records for the items in the source of the collection view.

    Declaration
    protected override RecordsList CreateRecords()
    Returns
    Type Description
    RecordsList

    The list of records created for the items in the source of the collection view.

    Overrides
    QueryableCollectionView.CreateRecords()

    EnsureView()

    Ensures sorting, grouping and filtering by refreshing the view with updated collection.

    Declaration
    protected override void EnsureView()
    Overrides
    CollectionViewAdv.EnsureView()

    GetComparerIndex(Object, Int32)

    Compares the given index and the index corresponding to the given record.

    Call this method when you need to find the compared index of item based on sorting

    Declaration
    protected override int GetComparerIndex(object record, int index)
    Parameters
    Type Name Description
    System.Object record

    The record whose index is to be compared with the given index.

    System.Int32 index

    The index which is to be compared

    Returns
    Type Description
    System.Int32

    Gets the comparer index based on the given index and the index corresponding to the given record.

    Overrides
    CollectionViewAdv.GetComparerIndex(Object, Int32)

    GetGroupResult(String[])

    Gets the IEnumerable collection of group result for the array of group-by.

    Declaration
    protected override IEnumerable<GroupResult> GetGroupResult(string[] groupBy)
    Parameters
    Type Name Description
    System.String[] groupBy

    The array of groups

    Returns
    Type Description
    System.Collections.Generic.IEnumerable<GroupResult>

    The IEnumerable collection of group result for the array of group-by.

    Overrides
    QueryableCollectionView.GetGroupResult(String[])

    GetQueryableSource()

    Returns the IQueryable source of the collection view.

    Declaration
    protected override IQueryable GetQueryableSource()
    Returns
    Type Description
    System.Linq.IQueryable

    The IQueryable source of the collection view.

    Overrides
    QueryableCollectionView.GetQueryableSource()
    Remarks

    PagedCollectionView returns paged source as IQueryable. Returning query will be sorted query in the case of normal VirtualizingCollectionView. It will be sorted and filtered query in the case of PagedCollectionVeiw and OnDemand VirtualizingCollectionView.

    LoadDynamicItems(Int32, IEnumerable)

    Loads the given items starting from the given page index, dynamically to the page.

    Declaration
    public void LoadDynamicItems(int startIndex, IEnumerable items)
    Parameters
    Type Name Description
    System.Int32 startIndex

    The start index to load the items.

    System.Collections.IEnumerable items

    The items to be loaded to the page.

    MoveToFirstPage()

    Moves to the first page.

    Declaration
    public bool MoveToFirstPage()
    Returns
    Type Description
    System.Boolean

    Returns a boolean value indicating whether moved to the first page or not.

    MoveToLastPage()

    Moves to the last page.

    Declaration
    public bool MoveToLastPage()
    Returns
    Type Description
    System.Boolean

    Returns a boolean value indicating whether moved to the last page or not.

    MoveToNextPage()

    Moves to the next page.

    Declaration
    public bool MoveToNextPage()
    Returns
    Type Description
    System.Boolean

    Returns a boolean value indicating whether moved to the next page or not.

    MoveToPage(Int32)

    Moves to the given page index.

    Declaration
    public virtual bool MoveToPage(int pageIndex)
    Parameters
    Type Name Description
    System.Int32 pageIndex

    The page index to move to.

    Returns
    Type Description
    System.Boolean

    Returns a boolean value indicating whether moved to the given page or not.

    MoveToPreviousPage()

    Moves to the previous page.

    Declaration
    public bool MoveToPreviousPage()
    Returns
    Type Description
    System.Boolean

    Returns a boolean value indicating whether moved to the previous page or not.

    NotifyPropertyChangedHandler(Object, PropertyChangedEventArgs)

    This method fires when the property is changed.

    Declaration
    protected override void NotifyPropertyChangedHandler(object sender, PropertyChangedEventArgs e)
    Parameters
    Type Name Description
    System.Object sender

    The sender of the event.

    System.ComponentModel.PropertyChangedEventArgs e

    The System.ComponentModel.PropertyChangedEventArgs that contains the event for the data.

    Overrides
    CollectionViewAdv.NotifyPropertyChangedHandler(Object, PropertyChangedEventArgs)

    RefreshFilter(Boolean)

    Refreshes the view when the filtering is applied through FilterRecord(Object) delegate.

    Declaration
    public override void RefreshFilter(bool isProgrammatic = false)
    Parameters
    Type Name Description
    System.Boolean isProgrammatic

    A boolean value indicating whether filtering is done programmatically.

    Overrides
    QueryableCollectionView.RefreshFilter(Boolean)

    RefreshSort()

    Refreshes sorting in the underlying collection of the SfDataGrid.

    Declaration
    protected override void RefreshSort()
    Overrides
    QueryableCollectionView.RefreshSort()

    Remove(Object)

    Removes the given item from the collection.

    Declaration
    public override void Remove(object item)
    Parameters
    Type Name Description
    System.Object item

    The item to be removed.

    Overrides
    CollectionViewAdv.Remove(Object)

    remove_OnDemandItemsLoading(OnDemandItemsLoadingEventHandler)

    Declaration
    public void remove_OnDemandItemsLoading(OnDemandItemsLoadingEventHandler value)
    Parameters
    Type Name Description
    OnDemandItemsLoadingEventHandler value

    remove_PageChanged(PageChangedEventHandler)

    Declaration
    public void remove_PageChanged(PageChangedEventHandler value)
    Parameters
    Type Name Description
    PageChangedEventHandler value

    remove_PageChanging(PageChangingEventHandler)

    Declaration
    public void remove_PageChanging(PageChangingEventHandler value)
    Parameters
    Type Name Description
    PageChangingEventHandler value

    ResetCache()

    Clears the cache while using OnDemandPaging.

    Declaration
    public void ResetCache()
    Remarks

    While navigating between pages, records are loaded through event and the loaded records will be maintained in cache. If you navigate to already navigated page, then records are loaded from cache and the event will not fire for that corresponding page. You can clear the cache by using this method and now the event will be raised when you navigate to the same page. And the records will be loaded through event instead of loading from cache.

    ResetCacheForPage(Int32)

    Reset the cache to the given page index.

    Declaration
    public void ResetCacheForPage(int pageIndex)
    Parameters
    Type Name Description
    System.Int32 pageIndex

    Index of the page to reset its cache.

    See Also
    ResetCache()

    SetSource(IEnumerable)

    Sets the given source to the collection view.

    Declaration
    protected override void SetSource(IEnumerable _source)
    Parameters
    Type Name Description
    System.Collections.IEnumerable _source

    The source to be set to the collection view.

    Overrides
    CollectionViewAdv.SetSource(IEnumerable)

    UpdateCollectionView(Object, NotifyCollectionChangedEventArgs)

    This method fires when the collection is changed.

    Declaration
    protected override void UpdateCollectionView(object sender, NotifyCollectionChangedEventArgs e)
    Parameters
    Type Name Description
    System.Object sender

    The original sender of the event.

    System.Collections.Specialized.NotifyCollectionChangedEventArgs e

    The System.Collections.Specialized.NotifyCollectionChangedAction which represents the collection changed action.

    Overrides
    CollectionViewAdv.UpdateCollectionView(Object, NotifyCollectionChangedEventArgs)

    Events

    OnDemandItemsLoading

    Occurs when the items are loaded on demand to the page.

    Declaration
    public event OnDemandItemsLoadingEventHandler OnDemandItemsLoading
    Event Type
    Type
    OnDemandItemsLoadingEventHandler

    PageChanged

    Occurs when the page is changed.

    Declaration
    public event PageChangedEventHandler PageChanged
    Event Type
    Type
    PageChangedEventHandler

    PageChanging

    Occurs when the page is changing.

    Declaration
    public event PageChangingEventHandler PageChanging
    Event Type
    Type
    PageChangingEventHandler

    Implements

    ICollectionViewAdv
    System.Collections.IEnumerable
    System.Collections.Specialized.INotifyCollectionChanged
    System.ComponentModel.INotifyPropertyChanged
    ISupportInitialize
    System.IDisposable
    IPropertyChangedEventHandler
    IEditableCollectionView
    ISupportIncrementalLoading
    IUnboundExpressionFunc
    IGridViewNotifier
    IFilterExt
    IParallelizableView

    Extension Methods

    DataTableCollectionViewExt.GetFilterString(CollectionViewAdv)
    DataTableCollectionViewExt.GetFilterString(CollectionViewAdv, String, Boolean)
    DataTableCollectionViewExt.GetClonedSource(CollectionViewAdv)
    QueryableCollectionViewExtensions.GetPredicateExpressionExt(CollectionViewAdv, IQueryable, out ParameterExpression)
    QueryableCollectionViewExtensions.GetPredicateExpressionExt(CollectionViewAdv, IQueryable, out ParameterExpression, String, Boolean)
    CollectionViewExtensions.GetITypedListFunc(CollectionViewAdv, String)
    CollectionViewExtensions.GetITypedListExpressionFunc(CollectionViewAdv, String)
    CollectionViewExtensions.IsITypedListSource(CollectionViewAdv)
    CollectionViewExtensions.ApplyFilters(CollectionViewAdv, ObservableCollection<IFilterDefinition>, String)
    Back to top Generated by DocFX
    Copyright © 2001 - 2025 Syncfusion Inc. All Rights Reserved