-
-
Notifications
You must be signed in to change notification settings - Fork 725
/
IQuery.cs
38 lines (33 loc) · 974 Bytes
/
IQuery.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
using System.Threading.Tasks;
using System;
using System.IO;
using System.Threading;
namespace HotChocolate.Execution
{
/// <summary>
/// Represents an executable query.
/// </summary>
public interface IQuery
{
/// <summary>
/// Writes the current query to the output stream.
/// </summary>
void WriteTo(Stream output);
/// <summary>
/// Writes the current query to the output stream.
/// </summary>
Task WriteToAsync(Stream output);
/// <summary>
/// Writes the current query to the output stream.
/// </summary>
Task WriteToAsync(Stream output, CancellationToken cancellationToken);
/// <summary>
/// Returns the binary query representation.
/// </summary>
ReadOnlySpan<byte> AsSpan();
/// <summary>
/// Returns the query string representation.
/// </summary>
string ToString();
}
}