Table of Contents

Class TruncatedCollection<T>

Namespace
System.Web.Http.OData.Query
Assembly
System.Web.Http.OData.dll

Represents a class that truncates a collection to a given page size.

public class TruncatedCollection<T> : List<T>, IList<T>, ICollection<T>, IList, ICollection, IReadOnlyList<T>, IReadOnlyCollection<T>, ITruncatedCollection, IEnumerable<T>, IEnumerable

Type Parameters

T

The collection element type.

Inheritance
List<T>
TruncatedCollection<T>
Implements
Inherited Members

Constructors

TruncatedCollection(IEnumerable<T>, int)

Initializes a new instance of the TruncatedCollection<T> class.

public TruncatedCollection(IEnumerable<T> source, int pageSize)

Parameters

source IEnumerable<T>

The collection to be truncated.

pageSize int

The page size.

TruncatedCollection(IQueryable<T>, int)

Initializes a new instance of the TruncatedCollection<T> class.

public TruncatedCollection(IQueryable<T> source, int pageSize)

Parameters

source IQueryable<T>

The queryable collection to be truncated.

pageSize int

The page size.

Properties

IsTruncated

public bool IsTruncated { get; }

Property Value

bool

PageSize

public int PageSize { get; }

Property Value

int