Method GetAvailableAsync
- Namespace
- MVVrus.AspNetCore.ActiveSession
- Assembly
- MVVrus.AspNetCore.ActiveSession.dll
GetAvailableAsync(int, int, string?, CancellationToken)
Asynchronous counterpart of the GetAvailable(int, int, string?) method.
ValueTask<RunnerResult<TResult>> GetAvailableAsync(int Advance = 2147483647, int StartPosition = -1, string? TraceIdentifier = null, CancellationToken Token = default)
Parameters
Advance
int- Desired increment of the runner's Position, at which the fetch should stop. If the backgound process did not get so far, this method returns the result for the last Position reached. In general, the value of this param should be positive, zero ( DEFAULT_ADVANCE) value having a special meaning.
StartPosition
int-
Position value from which a fetch of the result should begin. In general, value of this parameter should be non-negative (except for the special value below) and not less than value of the Position property. Use CURRENT_POSITION constant to continue to fetch result from the last position fetched. TraceIdentifier
string- String that can be used for tracing.
Token
CancellationTokenCan be used for cooperative cancellation of the operation initiated by this method (i.e. cancellation of the result task).
Returns
- ValueTask<RunnerResult<TResult>>
A ValueTask<TResult> wrapping a value returned by GetAvailable(int, int, string?) method call (possibly from a remote host)