AWS IoT Device SDK C: Jobs
AWS IoT Jobs library
Return to main page ↑
AwsIotJobsCallbackInfo_t Struct Reference

Information on a user-provided Jobs callback function. More...

#include <aws_iot_jobs_types.h>

Data Fields

void * pCallbackContext
 The first parameter to pass to the callback function.
 
void(* function )(void *, AwsIotJobsCallbackParam_t *)
 User-provided callback function signature. More...
 
void(* oldFunction )(void *, AwsIotJobsCallbackParam_t *)
 Callback function to replace when passed to AwsIotJobs_SetNotifyNextCallback or AwsIotJobs_SetNotifyPendingCallback. More...
 

Detailed Description

Information on a user-provided Jobs callback function.

Parameter for: AwsIotJobs_GetPendingAsync, AwsIotJobs_StartNextAsync, AwsIotJobs_DescribeAsync, AwsIotJobs_UpdateAsync, AwsIotJobs_SetNotifyPendingCallback, AwsIotJobs_SetNotifyNextCallback

Provides a function to be invoked when a Jobs operation completes or when a Jobs document is received on a callback topic (notify-pending or notify-next).

All instances of AwsIotJobsCallbackInfo_t should be initialized with AWS_IOT_JOBS_CALLBACK_INFO_INITIALIZER.

Field Documentation

◆ function

void( * AwsIotJobsCallbackInfo_t::function) (void *, AwsIotJobsCallbackParam_t *)

User-provided callback function signature.

Parameters
[in]void*AwsIotJobsCallbackInfo_t.pCallbackContext
[in]AwsIotJobsCallbackParam_t*Details on the outcome of the Jobs operation or an incoming Job document.
See also
AwsIotJobsCallbackParam_t for more information on the second parameter.

◆ oldFunction

void( * AwsIotJobsCallbackInfo_t::oldFunction) (void *, AwsIotJobsCallbackParam_t *)

Callback function to replace when passed to AwsIotJobs_SetNotifyNextCallback or AwsIotJobs_SetNotifyPendingCallback.

This member is ignored by Jobs operation functions.

The number of callbacks of each type that may be registered for each Thing is limited by AWS_IOT_JOBS_NOTIFY_CALLBACKS. If AWS_IOT_JOBS_NOTIFY_CALLBACKS is 2, that means that a maximum of 2 NOTIFY PENDING and 2 NOTIFY NEXT callbacks (4 total callbacks) may be set. This member is used to replace an existing callback with a new one.

To add a new callback:

callbackInfo.function = _newCallback;
callbackInfo.oldFunction = NULL;

For example, if the function _oldCallback() is currently registered:


The documentation for this struct was generated from the following file: