forked from nhibernate/nhibernate-core
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathICriteria.cs
66 lines (56 loc) · 2.42 KB
/
ICriteria.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by AsyncGenerator.
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
using System;
using System.Collections;
using System.Collections.Generic;
using System.Threading;
using NHibernate.Criterion;
using NHibernate.SqlCommand;
using NHibernate.Transform;
namespace NHibernate
{
using System.Threading.Tasks;
public partial interface ICriteria : ICloneable
{
/// <summary>
/// Get the results
/// </summary>
/// <param name="cancellationToken">A cancellation token that can be used to cancel the work</param>
/// <returns></returns>
Task<IList> ListAsync(CancellationToken cancellationToken = default(CancellationToken));
/// <summary>
/// Convenience method to return a single instance that matches
/// the query, or null if the query returns no results.
/// </summary>
/// <param name="cancellationToken">A cancellation token that can be used to cancel the work</param>
/// <returns>the single result or <see langword="null" /></returns>
/// <exception cref="HibernateException">
/// If there is more than one matching result
/// </exception>
Task<object> UniqueResultAsync(CancellationToken cancellationToken = default(CancellationToken));
#region NHibernate specific
/// <summary>
/// Get the results and fill the <see cref="IList"/>
/// </summary>
/// <param name="results">The list to fill with the results.</param>
/// <param name="cancellationToken">A cancellation token that can be used to cancel the work</param>
Task ListAsync(IList results, CancellationToken cancellationToken = default(CancellationToken));
/// <summary>
/// Strongly-typed version of <see cref="List()" />.
/// </summary>
/// <param name="cancellationToken">A cancellation token that can be used to cancel the work</param>
Task<IList<T>> ListAsync<T>(CancellationToken cancellationToken = default(CancellationToken));
/// <summary>
/// Strongly-typed version of <see cref="UniqueResult()" />.
/// </summary>
/// <param name="cancellationToken">A cancellation token that can be used to cancel the work</param>
Task<T> UniqueResultAsync<T>(CancellationToken cancellationToken = default(CancellationToken));
#endregion
}
}