Share via


IAsyncQueryable<TEntity>.QueryAsync Method

Definition

Overloads

QueryAsync(CancellationToken)

Starts a query and receive results asynchronously. Note: the result can only be accessed once, and cannot be reset.

QueryAsync(ICommonQueryableSpace, CancellationToken)

Starts a query and receive results asynchronously. Note: the result can only be accessed once, and cannot be reset.

QueryAsync(CancellationToken)

Starts a query and receive results asynchronously. Note: the result can only be accessed once, and cannot be reset.

public System.Collections.Generic.IAsyncEnumerable<Microsoft.VisualStudio.ProjectSystem.Query.IQueryResultItem<TEntity>> QueryAsync (System.Threading.CancellationToken cancellationToken);
abstract member QueryAsync : System.Threading.CancellationToken -> System.Collections.Generic.IAsyncEnumerable<Microsoft.VisualStudio.ProjectSystem.Query.IQueryResultItem<'Entity>>
Public Function QueryAsync (cancellationToken As CancellationToken) As IAsyncEnumerable(Of IQueryResultItem(Of TEntity))

Parameters

cancellationToken
CancellationToken

A cancellation token to abort the query when the left behind part of the results is no longer needed.

Returns

An enumerable to allow retrieving data asynchronously.

Remarks

The implementation today only benefits VS in-proc consumers. This will be addressed in the future.

Applies to

QueryAsync(ICommonQueryableSpace, CancellationToken)

Starts a query and receive results asynchronously. Note: the result can only be accessed once, and cannot be reset.

public System.Collections.Generic.IAsyncEnumerable<Microsoft.VisualStudio.ProjectSystem.Query.IQueryResultItem<TEntity>> QueryAsync (Microsoft.VisualStudio.ProjectSystem.Query.ICommonQueryableSpace queryableSpace, System.Threading.CancellationToken cancellationToken);
abstract member QueryAsync : Microsoft.VisualStudio.ProjectSystem.Query.ICommonQueryableSpace * System.Threading.CancellationToken -> System.Collections.Generic.IAsyncEnumerable<Microsoft.VisualStudio.ProjectSystem.Query.IQueryResultItem<'Entity>>
Public Function QueryAsync (queryableSpace As ICommonQueryableSpace, cancellationToken As CancellationToken) As IAsyncEnumerable(Of IQueryResultItem(Of TEntity))

Parameters

queryableSpace
ICommonQueryableSpace

The model space to execute the query.

cancellationToken
CancellationToken

A cancellation token to abort the query when the left behind part of the results is no longer needed.

Returns

An enumerable to allow retrieving data asynchronously.

Remarks

The implementation today only benefits VS in-proc consumers. This will be addressed in the future.

Applies to