DmGroupQuery`3
Namespace: MJCZone.DapperMatic.Dml
Assembly: MJCZone.DapperMatic
Summary
Groups read as something made of their keys and aggregates.
sealed public
Contents
Methods (8)
Methods
| Method | Summary |
|---|---|
| ToListAsync | Reads the groups. |
| FirstAsync | Reads the first group, in the query's order. |
| SingleAsync | Reads the one group the query returns. |
| ToSql | Writes the SQL that CancellationToken) runs, without running it.... |
| GetType | |
| ToString | |
| Equals | |
| GetHashCode |
ToListAsync
Reads the groups.
csharp
Task<List<TResult>> ToListAsync(
IDbTransaction tx,
CancellationToken cancellationToken)Parameters
- tx (IDbTransaction) - The transaction to use, or null.
- cancellationToken (CancellationToken) - The cancellation token.
Returns
Type: Task<List<TResult>>
The results.
FirstAsync
Reads the first group, in the query's order.
csharp
Task<TResult?> FirstAsync(
IDbTransaction tx,
CancellationToken cancellationToken)Parameters
- tx (IDbTransaction) - The transaction to use, or null.
- cancellationToken (CancellationToken) - The cancellation token.
Returns
Type: Task<TResult?>
The result, or the default if there are no groups.
SingleAsync
Reads the one group the query returns.
csharp
Task<TResult?> SingleAsync(
IDbTransaction tx,
CancellationToken cancellationToken)Parameters
- tx (IDbTransaction) - The transaction to use, or null.
- cancellationToken (CancellationToken) - The cancellation token.
Returns
Type: Task<TResult?>
The result, or the default if there are no groups.
ToSql
Writes the SQL that CancellationToken) runs, without running it.
csharp
DmStatement ToSql()Returns
Type: DmStatement
The SQL and its parameters.
GetType
csharp
GetType()ToString
csharp
ToString()Equals
csharp
Equals()GetHashCode
csharp
GetHashCode()