Task Pool API Reference
Task pool library
IotTaskPool_CreateJob

Creates a job for the task pool around a user-provided storage.

void * pUserContext,
IotTaskPoolJobStorage_t * const pJobStorage,
IotTaskPoolJob_t * const pJob );

This function may allocate memory to hold the state for a job.

Parameters
[in]userCallbackA user-specified callback for the job.
[in]pUserContextA user-specified context for the callback.
[in]pJobStorageThe storage for the job data structure.
[out]pJobA pointer to an instance of IotTaskPoolJob_t that will be initialized when this function returns successfully. This handle can be used to inspect the job status with IotTaskPool_GetStatus or cancel the job with IotTaskPool_TryCancel, etc....
Returns
One of the following:
IotTaskPoolRoutine_t
void(* IotTaskPoolRoutine_t)(IotTaskPool_t pTaskPool, IotTaskPoolJob_t pJob, void *pUserContext)
Callback type for a user callback.
Definition: iot_taskpool_types.h:259
IotTaskPool_CreateJob
IotTaskPoolError_t IotTaskPool_CreateJob(IotTaskPoolRoutine_t userCallback, void *pUserContext, IotTaskPoolJobStorage_t *const pJobStorage, IotTaskPoolJob_t *const pJob)
Creates a job for the task pool around a user-provided storage.
Definition: iot_taskpool.c:281
IotTaskPoolJobStorage_t
The job storage data structure provides the storage for a statically allocated Task Pool Job instance...
Definition: iot_taskpool_types.h:223
IotTaskPoolError_t
IotTaskPoolError_t
Return codes of task pool functions.
Definition: iot_taskpool_types.h:50
IotTaskPoolJob_t
struct _taskPoolJob * IotTaskPoolJob_t
Opaque handle of a Task Pool Job.
Definition: iot_taskpool_types.h:246