XAsyncSchedule
Schedules work for the callback function of an asynchronous provider.Syntax
Parameters
asyncBlock _Inout_Type: XAsyncBlock* A pointer to the XAsyncBlock that was passed to XAsyncBegin for the asynchronous call. delayInMs _In_
Type: uint32_t How long the system should wait, in milliseconds, before scheduling the asynchronous call with the asynchronous queue.
Return value
Type: HRESULT ReturnsS_OK if successful; otherwise, returns an error code. For a list of error codes, see Error Codes.
Remarks
This function is optional, and provides more control over scheduling asynchronous work for an asynchronous provider. If the asynchronous work can be done through a system-managed asynchronous mechanism, such as overlapped I/O, you don’t need to call this function. If asynchronous work should be scheduled after a delay, specify in delayInMs the number of milliseconds that XAsyncSchedule should wait before it schedules asynchronous work. For an example of an asynchronous provider that usesXAsyncSchedule to schedule asynchronous work, see the “Async Library” section in Asynchronous Programming Model.
Requirements
Header: XAsyncProvider.h Library: xgameruntime.lib Supported platforms: Windows, XBOX One family consoles and XBOX Series consolesConceptual documentation
See also
XAsyncProvider MembersXAsyncBegin
XAsyncSchedule
Asynchronous Programming Model
