IVariantServiceProvider<TService>.GetServiceAsync Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets an implementation variant of TService.
public System.Threading.Tasks.ValueTask<TService> GetServiceAsync(System.Threading.CancellationToken cancellationToken);
abstract member GetServiceAsync : System.Threading.CancellationToken -> System.Threading.Tasks.ValueTask<'Service (requires 'Service : null)>
Public Function GetServiceAsync (cancellationToken As CancellationToken) As ValueTask(Of TService)
Parameters
- cancellationToken
- CancellationToken
The cancellation token to cancel the operation.
Returns
An implementation of TService.