Class PagingInfo

Namespace
Cratis.Arc.Queries
Assembly
Cratis.Arc.Core.dll

Represents the result coming from performing a query with a collection of items.

public record PagingInfo : IEquatable<PagingInfo>
Inheritance
PagingInfo
Implements
Inherited Members
Extension Methods

Constructors

PagingInfo(PagingInfo)

protected PagingInfo(PagingInfo original)

Parameters

original PagingInfo

PagingInfo(int, int, long)

Represents the result coming from performing a query with a collection of items.

public PagingInfo(int Page, int Size, long TotalItems)

Parameters

Page int

The page number.

Size int

The size of the page.

TotalItems long

The total number of items.

Fields

NotPaged

Represents a not paged result.

public static readonly PagingInfo NotPaged

Field Value

PagingInfo

Properties

EqualityContract

protected virtual Type EqualityContract { get; }

Property Value

Type

Page

The page number.

public int Page { get; init; }

Property Value

int

Size

The size of the page.

public int Size { get; init; }

Property Value

int

TotalItems

The total number of items.

public long TotalItems { get; init; }

Property Value

long

TotalPages

Gets the total number of pages.

public int TotalPages { get; }

Property Value

int

Methods

Deconstruct(out int, out int, out long)

public void Deconstruct(out int Page, out int Size, out long TotalItems)

Parameters

Page int
Size int
TotalItems long

Equals(PagingInfo?)

public virtual bool Equals(PagingInfo? other)

Parameters

other PagingInfo

Returns

bool

Equals(object?)

public override bool Equals(object? obj)

Parameters

obj object

Returns

bool

GetHashCode()

public override int GetHashCode()

Returns

int

PrintMembers(StringBuilder)

protected virtual bool PrintMembers(StringBuilder builder)

Parameters

builder StringBuilder

Returns

bool

ToString()

public override string ToString()

Returns

string

Operators

operator ==(PagingInfo?, PagingInfo?)

public static bool operator ==(PagingInfo? left, PagingInfo? right)

Parameters

left PagingInfo
right PagingInfo

Returns

bool

operator !=(PagingInfo?, PagingInfo?)

public static bool operator !=(PagingInfo? left, PagingInfo? right)

Parameters

left PagingInfo
right PagingInfo

Returns

bool