Fauna v10 .NET/C# Driver 1.0.1
 
Loading...
Searching...
No Matches
Public Member Functions | List of all members
Fauna.BaseClient Class Referenceabstract

The base class for Client and DataContext. More...

Inheritance diagram for Fauna.BaseClient:
Fauna.IClient Fauna.Client Fauna.Linq.DataContext

Public Member Functions

Task< QuerySuccess< T > > QueryAsync< T > (Query query, QueryOptions? queryOptions=null, CancellationToken cancel=default)
 Asynchronously executes a specified FQL query against the Fauna database and returns the typed result.
Template Parameters
TThe type of the result expected from the query, corresponding to the structure of the FQL query's expected response.
Parameters
queryThe FQL query object representing the query to be executed against the Fauna database.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use
Returns
A Task representing the asynchronous operation, which upon completion contains the result of the query execution as QuerySuccess<T>.
Exceptions
AuthenticationExceptionThrown when authentication fails due to invalid credentials or other authentication issues.
AuthorizationExceptionThrown when the client lacks sufficient permissions to execute the query.
QueryCheckExceptionThrown when the query has syntax errors or is otherwise malformed.
QueryRuntimeExceptionThrown when runtime errors occur during query execution, such as invalid arguments or operational failures.
AbortExceptionThrown when the FQL abort function is called within the query, containing the data provided during the abort operation.
InvalidRequestExceptionThrown for improperly formatted requests or requests that Fauna cannot process.
ContendedTransactionExceptionThrown when a transaction is aborted due to concurrent modification or contention issues.
ThrottlingExceptionThrown when the query exceeds established rate limits for the Fauna service.
QueryTimeoutExceptionThrown when the query execution time exceeds the specified or default timeout period.
ServiceExceptionThrown in response to internal Fauna service errors, indicating issues on the server side.
FaunaExceptionThrown for unexpected or miscellaneous errors not covered by the other specific exception types.

 
Task< QuerySuccess< object?> > QueryAsync (Query query, QueryOptions? queryOptions=null, CancellationToken cancel=default)
 Asynchronously executes a specified FQL query against the Fauna database.
Parameters
queryThe FQL query object representing the query to be executed against the Fauna database.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use.
Returns
A Task representing the asynchronous operation, which upon completion contains the result of the query execution.
Exceptions
AuthenticationExceptionThrown when authentication fails due to invalid credentials or other authentication issues.
AuthorizationExceptionThrown when the client lacks sufficient permissions to execute the query.
QueryCheckExceptionThrown when the query has syntax errors or is otherwise malformed.
QueryRuntimeExceptionThrown when runtime errors occur during query execution, such as invalid arguments or operational failures.
AbortExceptionThrown when the FQL abort function is called within the query, containing the data provided during the abort operation.
InvalidRequestExceptionThrown for improperly formatted requests or requests that Fauna cannot process.
ContendedTransactionExceptionThrown when a transaction is aborted due to concurrent modification or contention issues.
ThrottlingExceptionThrown when the query exceeds established rate limits for the Fauna service.
QueryTimeoutExceptionThrown when the query execution time exceeds the specified or default timeout period.
ServiceExceptionThrown in response to internal Fauna service errors, indicating issues on the server side.
FaunaExceptionThrown for unexpected or miscellaneous errors not covered by the other specific exception types.

 
Task< QuerySuccess< T > > QueryAsync< T > (Query query, ISerializer< T > serializer, QueryOptions? queryOptions=null, CancellationToken cancel=default)
 Asynchronously executes a specified FQL query against the Fauna database and returns the typed result.
Template Parameters
TThe type of the result expected from the query, corresponding to the structure of the FQL query's expected response.
Parameters
queryThe FQL query object representing the query to be executed against the Fauna database.
serializerA serializer for the success data type.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use.
Returns
A Task representing the asynchronous operation, which upon completion contains the result of the query execution as QuerySuccess<T>.
Exceptions
AuthenticationExceptionThrown when authentication fails due to invalid credentials or other authentication issues.
AuthorizationExceptionThrown when the client lacks sufficient permissions to execute the query.
QueryCheckExceptionThrown when the query has syntax errors or is otherwise malformed.
QueryRuntimeExceptionThrown when runtime errors occur during query execution, such as invalid arguments or operational failures.
AbortExceptionThrown when the FQL abort function is called within the query, containing the data provided during the abort operation.
InvalidRequestExceptionThrown for improperly formatted requests or requests that Fauna cannot process.
ContendedTransactionExceptionThrown when a transaction is aborted due to concurrent modification or contention issues.
ThrottlingExceptionThrown when the query exceeds established rate limits for the Fauna service.
QueryTimeoutExceptionThrown when the query execution time exceeds the specified or default timeout period.
ServiceExceptionThrown in response to internal Fauna service errors, indicating issues on the server side.
FaunaExceptionThrown for unexpected or miscellaneous errors not covered by the other specific exception types.

 
Task< QuerySuccess< object?> > QueryAsync (Query query, ISerializer serializer, QueryOptions? queryOptions=null, CancellationToken cancel=default)
 Asynchronously executes a specified FQL query against the Fauna database and returns the typed result.
Parameters
queryThe FQL query object representing the query to be executed against the Fauna database.
serializerA serializer for the success data type.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation toke to use.
Returns
A Task representing the asynchronous operation, which upon completion contains the result of the query execution.
Exceptions
AuthenticationExceptionThrown when authentication fails due to invalid credentials or other authentication issues.
AuthorizationExceptionThrown when the client lacks sufficient permissions to execute the query.
QueryCheckExceptionThrown when the query has syntax errors or is otherwise malformed.
QueryRuntimeExceptionThrown when runtime errors occur during query execution, such as invalid arguments or operational failures.
AbortExceptionThrown when the FQL abort function is called within the query, containing the data provided during the abort operation.
InvalidRequestExceptionThrown for improperly formatted requests or requests that Fauna cannot process.
ContendedTransactionExceptionThrown when a transaction is aborted due to concurrent modification or contention issues.
ThrottlingExceptionThrown when the query exceeds established rate limits for the Fauna service.
QueryTimeoutExceptionThrown when the query execution time exceeds the specified or default timeout period.
ServiceExceptionThrown in response to internal Fauna service errors, indicating issues on the server side.
FaunaExceptionThrown for unexpected or miscellaneous errors not covered by the other specific exception types.

 
IAsyncEnumerable< Page< T > > PaginateAsync< T > (Query query, QueryOptions? queryOptions=null, CancellationToken cancel=default)
 Asynchronously iterates over pages of a Fauna query result, automatically fetching subsequent pages using the 'after' cursor.
Template Parameters
TThe type of the data expected in each page.
Parameters
queryThe FQL query object representing the query to be executed against the Fauna database.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use.
Returns
An asynchronous enumerable of pages, each containing a list of items of type T .
This method handles pagination by sending multiple requests to Fauna as needed, based on the presence of an 'after' cursor in the query results.
 
IAsyncEnumerable< Page< T > > PaginateAsync< T > (Page< T > page, QueryOptions? queryOptions=null, CancellationToken cancel=default)
 Asynchronously iterates over pages of a Fauna query result, automatically fetching subsequent pages using the 'after' cursor. The provided page is the first page yielded.
Template Parameters
TThe type of the data expected in each page.
Parameters
pageThe initial page.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use.
Returns
An asynchronous enumerable of pages, each containing a list of items of type T .
This method handles pagination by sending multiple requests to Fauna as needed, based on the presence of an 'after' cursor in the query results.
 
IAsyncEnumerable< Page< object?> > PaginateAsync (Query query, QueryOptions? queryOptions=null, CancellationToken cancel=default)
 Asynchronously iterates over pages of a Fauna query result, automatically fetching subsequent pages using the 'after' cursor.
Parameters
queryThe FQL query object representing the query to be executed against the Fauna database.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use.
Returns
An asynchronous enumerable of pages, each containing a list of items.
This method handles pagination by sending multiple requests to Fauna as needed, based on the presence of an 'after' cursor in the query results.
 
IAsyncEnumerable< Page< object?> > PaginateAsync (Page< object?> page, QueryOptions? queryOptions=null, CancellationToken cancel=default)
 Asynchronously iterates over pages of a Fauna query result, automatically fetching subsequent pages using the 'after' cursor. The provided page is the first page yielded.
Parameters
pageThe initial page.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use.
Returns
An asynchronous enumerable of pages, each containing a list of items.
This method handles pagination by sending multiple requests to Fauna as needed, based on the presence of an 'after' cursor in the query results.
 
IAsyncEnumerable< Page< T > > PaginateAsync< T > (Query query, ISerializer< T > elemSerializer, QueryOptions? queryOptions=null, CancellationToken cancel=default)
 Asynchronously iterates over pages of a Fauna query result, automatically fetching subsequent pages using the 'after' cursor.
Template Parameters
TThe type of the data expected in each page.
Parameters
queryThe FQL query object representing the query to be executed against the Fauna database.
elemSerializerA data serializer for the page element type.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use.
Returns
An asynchronous enumerable of pages, each containing a list of items of type T .
This method handles pagination by sending multiple requests to Fauna as needed, based on the presence of an 'after' cursor in the query results.
 
IAsyncEnumerable< Page< T > > PaginateAsync< T > (Page< T > page, ISerializer< T > elemSerializer, QueryOptions? queryOptions=null, CancellationToken cancel=default)
 Asynchronously iterates over pages of a Fauna query result, automatically fetching subsequent pages using the 'after' cursor. The provided page is the first page yielded.
Template Parameters
TThe type of the data expected in each page.
Parameters
pageThe initial page.
elemSerializerA data serializer for the page element type.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use.
Returns
An asynchronous enumerable of pages, each containing a list of items of type T .
This method handles pagination by sending multiple requests to Fauna as needed, based on the presence of an 'after' cursor in the query results.
 
IAsyncEnumerable< Page< object?> > PaginateAsync (Query query, ISerializer elemSerializer, QueryOptions? queryOptions=null, CancellationToken cancel=default)
 Asynchronously iterates over pages of a Fauna query result, automatically fetching subsequent pages using the 'after' cursor.
Parameters
queryThe FQL query object representing the query to be executed against the Fauna database.
elemSerializerA data serializer for the page element type.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use.
Returns
A Task representing the asynchronous operation, which upon completion contains the result of the query execution.
This method handles pagination by sending multiple requests to Fauna as needed, based on the presence of an 'after' cursor in the query results.
 
IAsyncEnumerable< Page< object?> > PaginateAsync (Page< object?> page, ISerializer elemSerializer, QueryOptions? queryOptions=null, CancellationToken cancel=default)
 Asynchronously iterates over pages of a Fauna query result, automatically fetching subsequent pages using the 'after' cursor. The provided page is the first page yielded.
Parameters
pageThe FQL query object representing the query to be executed against the Fauna database.
elemSerializerA data serializer for the page element type.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use.
Returns
A Task representing the asynchronous operation, which upon completion contains the result of the query execution.
This method handles pagination by sending multiple requests to Fauna as needed, based on the presence of an 'after' cursor in the query results.
 
async Task< T > LoadRefAsync< T > (BaseRef< T > reference, CancellationToken cancel=default)
 Asynchronously executes a specified FQL query against the Fauna database and returns the typed result.
Template Parameters
TThe type of the result expected from the query, corresponding to the structure of the FQL query's expected response.
Parameters
referenceThe reference to load.
cancelA cancellation token to use
Returns
A Task representing the asynchronous operation, which upon completion contains the result of the query execution as QuerySuccess<T>.
Exceptions
AuthenticationExceptionThrown when authentication fails due to invalid credentials or other authentication issues.
AuthorizationExceptionThrown when the client lacks sufficient permissions to execute the query.
QueryCheckExceptionThrown when the query has syntax errors or is otherwise malformed.
QueryRuntimeExceptionThrown when runtime errors occur during query execution, such as invalid arguments or operational failures.
AbortExceptionThrown when the FQL abort function is called within the query, containing the data provided during the abort operation.
InvalidRequestExceptionThrown for improperly formatted requests or requests that Fauna cannot process.
ContendedTransactionExceptionThrown when a transaction is aborted due to concurrent modification or contention issues.
ThrottlingExceptionThrown when the query exceeds established rate limits for the Fauna service.
QueryTimeoutExceptionThrown when the query execution time exceeds the specified or default timeout period.
ServiceExceptionThrown in response to internal Fauna service errors, indicating issues on the server side.
FaunaExceptionThrown for unexpected or miscellaneous errors not covered by the other specific exception types.
NullDocumentExceptionThrown when the provided reference does not exist.

 
async Task< StreamEnumerable< T > > EventStreamAsync< T > (Query query, QueryOptions? queryOptions=null, StreamOptions? streamOptions=null, CancellationToken cancellationToken=default)
 Retrieves a Stream token from Fauna and returns a StreamEnumerable for the stream events.
 
async Task< StreamEnumerable< T > > EventStreamAsync< T > (EventSource eventSource, CancellationToken cancellationToken=default)
 Returns a StreamEnumerable for the stream events.
 
async Task< FeedEnumerable< T > > EventFeedAsync< T > (EventSource eventSource, FeedOptions? feedOptions=null, CancellationToken cancellationToken=default)
 Opens the event feed with Fauna and returns an enumerator for the events.
 
async Task< FeedEnumerable< T > > EventFeedAsync< T > (Query query, FeedOptions? feedOptions=null, CancellationToken cancellationToken=default)
 Opens the event feed with Fauna and returns an enumerator for the events.
 
IAsyncEnumerator< Event< T > > SubscribeStream< T > (EventSource eventSource, MappingContext ctx, CancellationToken cancel=default)
 Opens the stream with Fauna and returns an enumerator for the stream events.
 
IAsyncEnumerator< FeedPage< T > > SubscribeFeed< T > (EventSource eventSource, MappingContext ctx, CancellationToken cancel=default)
 Opens an event feed with Fauna and returns an enumerator for the events.
 

Detailed Description

The base class for Client and DataContext.

Definition at line 369 of file IClient.cs.

Member Function Documentation

◆ EventFeedAsync< T >() [1/2]

async Task< FeedEnumerable< T > > Fauna.BaseClient.EventFeedAsync< T > ( EventSource  eventSource,
FeedOptions feedOptions = null,
CancellationToken  cancellationToken = default 
)

Opens the event feed with Fauna and returns an enumerator for the events.

Parameters
eventSource
feedOptionsThe options for the feed.
cancellationTokenThe cancellation token for the operation.
Template Parameters
TWhich Type to map the Events to.
Returns
Type Constraints
T :notnull 

Definition at line 630 of file IClient.cs.

◆ EventFeedAsync< T >() [2/2]

async Task< FeedEnumerable< T > > Fauna.BaseClient.EventFeedAsync< T > ( Query  query,
FeedOptions feedOptions = null,
CancellationToken  cancellationToken = default 
)

Opens the event feed with Fauna and returns an enumerator for the events.

Parameters
queryThe query to create the stream from Fauna.
feedOptionsThe options for the feed.
cancellationTokenThe cancellation token for the operation.
Template Parameters
TWhich Type to map the Events to.
Returns
Type Constraints
T :notnull 

Definition at line 650 of file IClient.cs.

◆ EventStreamAsync< T >() [1/2]

async Task< StreamEnumerable< T > > Fauna.BaseClient.EventStreamAsync< T > ( EventSource  eventSource,
CancellationToken  cancellationToken = default 
)

Returns a StreamEnumerable for the stream events.

Parameters
eventSource
cancellationToken
Template Parameters
TWhich Type to map the Events to.
Returns
Type Constraints
T :notnull 

Definition at line 598 of file IClient.cs.

◆ EventStreamAsync< T >() [2/2]

async Task< StreamEnumerable< T > > Fauna.BaseClient.EventStreamAsync< T > ( Query  query,
QueryOptions queryOptions = null,
StreamOptions streamOptions = null,
CancellationToken  cancellationToken = default 
)

Retrieves a Stream token from Fauna and returns a StreamEnumerable for the stream events.

Template Parameters
TEvent Data will be deserialized to this type.
Parameters
queryThe query to create the stream from Fauna.
queryOptionsThe options for the query.
streamOptionsThe options for the stream.
cancellationTokenThe cancellation token.
Returns
A task that represents the asynchronous operation. The task result contains a stream of events.
Type Constraints
T :notnull 

Definition at line 578 of file IClient.cs.

◆ LoadRefAsync< T >()

async Task< T > Fauna.BaseClient.LoadRefAsync< T > ( BaseRef< T >  reference,
CancellationToken  cancel = default 
)

Asynchronously executes a specified FQL query against the Fauna database and returns the typed result.

Template Parameters
TThe type of the result expected from the query, corresponding to the structure of the FQL query's expected response.
Parameters
referenceThe reference to load.
cancelA cancellation token to use
Returns
A Task representing the asynchronous operation, which upon completion contains the result of the query execution as QuerySuccess<T>.
Exceptions
AuthenticationExceptionThrown when authentication fails due to invalid credentials or other authentication issues.
AuthorizationExceptionThrown when the client lacks sufficient permissions to execute the query.
QueryCheckExceptionThrown when the query has syntax errors or is otherwise malformed.
QueryRuntimeExceptionThrown when runtime errors occur during query execution, such as invalid arguments or operational failures.
AbortExceptionThrown when the FQL abort function is called within the query, containing the data provided during the abort operation.
InvalidRequestExceptionThrown for improperly formatted requests or requests that Fauna cannot process.
ContendedTransactionExceptionThrown when a transaction is aborted due to concurrent modification or contention issues.
ThrottlingExceptionThrown when the query exceeds established rate limits for the Fauna service.
QueryTimeoutExceptionThrown when the query execution time exceeds the specified or default timeout period.
ServiceExceptionThrown in response to internal Fauna service errors, indicating issues on the server side.
FaunaExceptionThrown for unexpected or miscellaneous errors not covered by the other specific exception types.
NullDocumentExceptionThrown when the provided reference does not exist.

Implements Fauna.IClient.

Type Constraints
T :notnull 

Definition at line 495 of file IClient.cs.

◆ PaginateAsync() [1/4]

IAsyncEnumerable< Page< object?> > Fauna.BaseClient.PaginateAsync ( Page< object?>  page,
ISerializer  elemSerializer,
QueryOptions queryOptions = null,
CancellationToken  cancel = default 
)

Asynchronously iterates over pages of a Fauna query result, automatically fetching subsequent pages using the 'after' cursor. The provided page is the first page yielded.

Parameters
pageThe FQL query object representing the query to be executed against the Fauna database.
elemSerializerA data serializer for the page element type.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use.
Returns
A Task representing the asynchronous operation, which upon completion contains the result of the query execution.
This method handles pagination by sending multiple requests to Fauna as needed, based on the presence of an 'after' cursor in the query results.

Implements Fauna.IClient.

Definition at line 483 of file IClient.cs.

◆ PaginateAsync() [2/4]

IAsyncEnumerable< Page< object?> > Fauna.BaseClient.PaginateAsync ( Page< object?>  page,
QueryOptions queryOptions = null,
CancellationToken  cancel = default 
)

Asynchronously iterates over pages of a Fauna query result, automatically fetching subsequent pages using the 'after' cursor. The provided page is the first page yielded.

Parameters
pageThe initial page.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use.
Returns
An asynchronous enumerable of pages, each containing a list of items.
This method handles pagination by sending multiple requests to Fauna as needed, based on the presence of an 'after' cursor in the query results.

Implements Fauna.IClient.

◆ PaginateAsync() [3/4]

IAsyncEnumerable< Page< object?> > Fauna.BaseClient.PaginateAsync ( Query  query,
ISerializer  elemSerializer,
QueryOptions queryOptions = null,
CancellationToken  cancel = default 
)

Asynchronously iterates over pages of a Fauna query result, automatically fetching subsequent pages using the 'after' cursor.

Parameters
queryThe FQL query object representing the query to be executed against the Fauna database.
elemSerializerA data serializer for the page element type.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use.
Returns
A Task representing the asynchronous operation, which upon completion contains the result of the query execution.
This method handles pagination by sending multiple requests to Fauna as needed, based on the presence of an 'after' cursor in the query results.

Implements Fauna.IClient.

Definition at line 471 of file IClient.cs.

◆ PaginateAsync() [4/4]

IAsyncEnumerable< Page< object?> > Fauna.BaseClient.PaginateAsync ( Query  query,
QueryOptions queryOptions = null,
CancellationToken  cancel = default 
)

Asynchronously iterates over pages of a Fauna query result, automatically fetching subsequent pages using the 'after' cursor.

Parameters
queryThe FQL query object representing the query to be executed against the Fauna database.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use.
Returns
An asynchronous enumerable of pages, each containing a list of items.
This method handles pagination by sending multiple requests to Fauna as needed, based on the presence of an 'after' cursor in the query results.

Implements Fauna.IClient.

◆ PaginateAsync< T >() [1/4]

IAsyncEnumerable< Page< T > > Fauna.BaseClient.PaginateAsync< T > ( Page< T >  page,
ISerializer< T >  elemSerializer,
QueryOptions queryOptions = null,
CancellationToken  cancel = default 
)

Asynchronously iterates over pages of a Fauna query result, automatically fetching subsequent pages using the 'after' cursor. The provided page is the first page yielded.

Template Parameters
TThe type of the data expected in each page.
Parameters
pageThe initial page.
elemSerializerA data serializer for the page element type.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use.
Returns
An asynchronous enumerable of pages, each containing a list of items of type T .
This method handles pagination by sending multiple requests to Fauna as needed, based on the presence of an 'after' cursor in the query results.

Implements Fauna.IClient.

Definition at line 460 of file IClient.cs.

◆ PaginateAsync< T >() [2/4]

IAsyncEnumerable< Page< T > > Fauna.BaseClient.PaginateAsync< T > ( Page< T >  page,
QueryOptions queryOptions = null,
CancellationToken  cancel = default 
)

Asynchronously iterates over pages of a Fauna query result, automatically fetching subsequent pages using the 'after' cursor. The provided page is the first page yielded.

Template Parameters
TThe type of the data expected in each page.
Parameters
pageThe initial page.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use.
Returns
An asynchronous enumerable of pages, each containing a list of items of type T .
This method handles pagination by sending multiple requests to Fauna as needed, based on the presence of an 'after' cursor in the query results.

Implements Fauna.IClient.

Type Constraints
T :notnull 
T :PaginateAsync 
T :page 
T :Serializer.Generate<T> 
T :MappingCtx 
T :queryOptions 
T :cancel 

◆ PaginateAsync< T >() [3/4]

IAsyncEnumerable< Page< T > > Fauna.BaseClient.PaginateAsync< T > ( Query  query,
ISerializer< T >  elemSerializer,
QueryOptions queryOptions = null,
CancellationToken  cancel = default 
)

Asynchronously iterates over pages of a Fauna query result, automatically fetching subsequent pages using the 'after' cursor.

Template Parameters
TThe type of the data expected in each page.
Parameters
queryThe FQL query object representing the query to be executed against the Fauna database.
elemSerializerA data serializer for the page element type.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use.
Returns
An asynchronous enumerable of pages, each containing a list of items of type T .
This method handles pagination by sending multiple requests to Fauna as needed, based on the presence of an 'after' cursor in the query results.

Implements Fauna.IClient.

Definition at line 449 of file IClient.cs.

◆ PaginateAsync< T >() [4/4]

IAsyncEnumerable< Page< T > > Fauna.BaseClient.PaginateAsync< T > ( Query  query,
QueryOptions queryOptions = null,
CancellationToken  cancel = default 
)

Asynchronously iterates over pages of a Fauna query result, automatically fetching subsequent pages using the 'after' cursor.

Template Parameters
TThe type of the data expected in each page.
Parameters
queryThe FQL query object representing the query to be executed against the Fauna database.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use.
Returns
An asynchronous enumerable of pages, each containing a list of items of type T .
This method handles pagination by sending multiple requests to Fauna as needed, based on the presence of an 'after' cursor in the query results.

Implements Fauna.IClient.

Type Constraints
T :notnull 
T :PaginateAsync 
T :query 
T :Serializer.Generate<T> 
T :MappingCtx 
T :queryOptions 
T :cancel 

◆ QueryAsync() [1/2]

Task< QuerySuccess< object?> > Fauna.BaseClient.QueryAsync ( Query  query,
ISerializer  serializer,
QueryOptions queryOptions = null,
CancellationToken  cancel = default 
)

Asynchronously executes a specified FQL query against the Fauna database and returns the typed result.

Parameters
queryThe FQL query object representing the query to be executed against the Fauna database.
serializerA serializer for the success data type.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation toke to use.
Returns
A Task representing the asynchronous operation, which upon completion contains the result of the query execution.
Exceptions
AuthenticationExceptionThrown when authentication fails due to invalid credentials or other authentication issues.
AuthorizationExceptionThrown when the client lacks sufficient permissions to execute the query.
QueryCheckExceptionThrown when the query has syntax errors or is otherwise malformed.
QueryRuntimeExceptionThrown when runtime errors occur during query execution, such as invalid arguments or operational failures.
AbortExceptionThrown when the FQL abort function is called within the query, containing the data provided during the abort operation.
InvalidRequestExceptionThrown for improperly formatted requests or requests that Fauna cannot process.
ContendedTransactionExceptionThrown when a transaction is aborted due to concurrent modification or contention issues.
ThrottlingExceptionThrown when the query exceeds established rate limits for the Fauna service.
QueryTimeoutExceptionThrown when the query execution time exceeds the specified or default timeout period.
ServiceExceptionThrown in response to internal Fauna service errors, indicating issues on the server side.
FaunaExceptionThrown for unexpected or miscellaneous errors not covered by the other specific exception types.

Implements Fauna.IClient.

◆ QueryAsync() [2/2]

Task< QuerySuccess< object?> > Fauna.BaseClient.QueryAsync ( Query  query,
QueryOptions queryOptions = null,
CancellationToken  cancel = default 
)

Asynchronously executes a specified FQL query against the Fauna database.

Parameters
queryThe FQL query object representing the query to be executed against the Fauna database.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use.
Returns
A Task representing the asynchronous operation, which upon completion contains the result of the query execution.
Exceptions
AuthenticationExceptionThrown when authentication fails due to invalid credentials or other authentication issues.
AuthorizationExceptionThrown when the client lacks sufficient permissions to execute the query.
QueryCheckExceptionThrown when the query has syntax errors or is otherwise malformed.
QueryRuntimeExceptionThrown when runtime errors occur during query execution, such as invalid arguments or operational failures.
AbortExceptionThrown when the FQL abort function is called within the query, containing the data provided during the abort operation.
InvalidRequestExceptionThrown for improperly formatted requests or requests that Fauna cannot process.
ContendedTransactionExceptionThrown when a transaction is aborted due to concurrent modification or contention issues.
ThrottlingExceptionThrown when the query exceeds established rate limits for the Fauna service.
QueryTimeoutExceptionThrown when the query execution time exceeds the specified or default timeout period.
ServiceExceptionThrown in response to internal Fauna service errors, indicating issues on the server side.
FaunaExceptionThrown for unexpected or miscellaneous errors not covered by the other specific exception types.

Implements Fauna.IClient.

◆ QueryAsync< T >() [1/2]

Task< QuerySuccess< T > > Fauna.BaseClient.QueryAsync< T > ( Query  query,
ISerializer< T >  serializer,
QueryOptions queryOptions = null,
CancellationToken  cancel = default 
)

Asynchronously executes a specified FQL query against the Fauna database and returns the typed result.

Template Parameters
TThe type of the result expected from the query, corresponding to the structure of the FQL query's expected response.
Parameters
queryThe FQL query object representing the query to be executed against the Fauna database.
serializerA serializer for the success data type.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use.
Returns
A Task representing the asynchronous operation, which upon completion contains the result of the query execution as QuerySuccess<T>.
Exceptions
AuthenticationExceptionThrown when authentication fails due to invalid credentials or other authentication issues.
AuthorizationExceptionThrown when the client lacks sufficient permissions to execute the query.
QueryCheckExceptionThrown when the query has syntax errors or is otherwise malformed.
QueryRuntimeExceptionThrown when runtime errors occur during query execution, such as invalid arguments or operational failures.
AbortExceptionThrown when the FQL abort function is called within the query, containing the data provided during the abort operation.
InvalidRequestExceptionThrown for improperly formatted requests or requests that Fauna cannot process.
ContendedTransactionExceptionThrown when a transaction is aborted due to concurrent modification or contention issues.
ThrottlingExceptionThrown when the query exceeds established rate limits for the Fauna service.
QueryTimeoutExceptionThrown when the query execution time exceeds the specified or default timeout period.
ServiceExceptionThrown in response to internal Fauna service errors, indicating issues on the server side.
FaunaExceptionThrown for unexpected or miscellaneous errors not covered by the other specific exception types.

Implements Fauna.IClient.

◆ QueryAsync< T >() [2/2]

Task< QuerySuccess< T > > Fauna.BaseClient.QueryAsync< T > ( Query  query,
QueryOptions queryOptions = null,
CancellationToken  cancel = default 
)

Asynchronously executes a specified FQL query against the Fauna database and returns the typed result.

Template Parameters
TThe type of the result expected from the query, corresponding to the structure of the FQL query's expected response.
Parameters
queryThe FQL query object representing the query to be executed against the Fauna database.
queryOptionsOptional parameters to customize the query execution, such as timeout settings and custom headers.
cancelA cancellation token to use
Returns
A Task representing the asynchronous operation, which upon completion contains the result of the query execution as QuerySuccess<T>.
Exceptions
AuthenticationExceptionThrown when authentication fails due to invalid credentials or other authentication issues.
AuthorizationExceptionThrown when the client lacks sufficient permissions to execute the query.
QueryCheckExceptionThrown when the query has syntax errors or is otherwise malformed.
QueryRuntimeExceptionThrown when runtime errors occur during query execution, such as invalid arguments or operational failures.
AbortExceptionThrown when the FQL abort function is called within the query, containing the data provided during the abort operation.
InvalidRequestExceptionThrown for improperly formatted requests or requests that Fauna cannot process.
ContendedTransactionExceptionThrown when a transaction is aborted due to concurrent modification or contention issues.
ThrottlingExceptionThrown when the query exceeds established rate limits for the Fauna service.
QueryTimeoutExceptionThrown when the query execution time exceeds the specified or default timeout period.
ServiceExceptionThrown in response to internal Fauna service errors, indicating issues on the server side.
FaunaExceptionThrown for unexpected or miscellaneous errors not covered by the other specific exception types.

Implements Fauna.IClient.

Type Constraints
T :notnull 
T :QueryAsync<T> 
T :query 
T :Serializer.Generate<T> 
T :MappingCtx 
T :queryOptions 
T :cancel 

◆ SubscribeFeed< T >()

IAsyncEnumerator< FeedPage< T > > Fauna.BaseClient.SubscribeFeed< T > ( EventSource  eventSource,
MappingContext  ctx,
CancellationToken  cancel = default 
)

Opens an event feed with Fauna and returns an enumerator for the events.

Template Parameters
TEvent Data will be deserialized to this type.
Parameters
eventSourceThe stream to subscribe to.
ctxMapping context for stream.
cancelThe cancellation token.
Returns
An async enumerator of stream events.
Type Constraints
T :notnull 

Definition at line 711 of file IClient.cs.

◆ SubscribeStream< T >()

IAsyncEnumerator< Event< T > > Fauna.BaseClient.SubscribeStream< T > ( EventSource  eventSource,
MappingContext  ctx,
CancellationToken  cancel = default 
)

Opens the stream with Fauna and returns an enumerator for the stream events.

Template Parameters
TEvent Data will be deserialized to this type.
Parameters
eventSourceThe stream to subscribe to.
ctxMapping context for stream.
cancelThe cancellation token.
Returns
An async enumerator of stream events.
Type Constraints
T :notnull 

Definition at line 695 of file IClient.cs.


The documentation for this class was generated from the following file: