AbstractSelectSorter<T> Class

Abstract base class for SELECT sorters.

C#
public abstract class AbstractSelectSorter<T> : SelectSorter<T>
where T : notnull

Type Parameters

T
notnull

The type of the result set.

Inheritance
AbstractSelectSorter<T>
Implements

Constructors

AbstractSelectSorter(string, Func<string, IEnumerable<T>>)

Abstract base class for SELECT sorters.

Properties

Text

Gets the SQL query text.

Methods

OrderBy(string[])

Description copied from interface: SelectSorter

Executes the query and gets the result in the order sorted by the specified columns.

Execute()

Description copied from interface: SelectTerminator

Executes the query and gets the result.

Limit(int)

Description copied from interface: SelectTerminator

Executes the query and limits the number of rows that the query returns.

LimitOffset(int, int)

Description copied from interface: SelectTerminator

Executes the query and limits the number of rows that the query returns and specifies the starting offset.

Equals(object) (Inherited from object)
GetHashCode() (Inherited from object)
GetType() (Inherited from object)
MemberwiseClone() (Inherited from object)
ToString() (Inherited from object)

Constructors Detail

AbstractSelectSorter(string, Func<string, IEnumerable<T>>)

Abstract base class for SELECT sorters.

C#
protected AbstractSelectSorter(string text, Func<string, IEnumerable<T>> executor)

Parameters

text
string

The SQL query text.

executor
Func<string, IEnumerable<T>>

The executor function.

Properties Detail

Text

Gets the SQL query text.

C#
protected string Text { get; }

Property Value

Methods Detail

OrderBy(string[])

Description copied from interface: SelectSorter

Executes the query and gets the result in the order sorted by the specified columns.

C#
public SelectTerminator<T> OrderBy(params string[] columns)

Parameters

columns
string[]

Returns

Description copied from interface: SelectSorter

The T objects representing the result of the query.

Implements

Remarks

Description copied from interface: SelectSorter

The result that this method returns represents that of SELECT ... FROM ... ORDER BY columns.

Execute()

Description copied from interface: SelectTerminator

Executes the query and gets the result.

C#
public IEnumerable<T> Execute()

Returns

Description copied from interface: SelectTerminator

The T objects representing the result of the query.

Implements

Limit(int)

Description copied from interface: SelectTerminator

Executes the query and limits the number of rows that the query returns.

C#
public IEnumerable<T> Limit(int limit)

Parameters

limit
int

Returns

Description copied from interface: SelectTerminator

The T objects representing the limited result of the query.

Implements

LimitOffset(int, int)

Description copied from interface: SelectTerminator

Executes the query and limits the number of rows that the query returns and specifies the starting offset.

C#
public IEnumerable<T> LimitOffset(int limit, int offset)

Parameters

limit
int
offset
int

Returns

Description copied from interface: SelectTerminator

The T objects representing the limited result of the query.

Implements