void RegisterCompletionCallback( CompletionCallback pfCompletionCallback, const UserContext & oContext, qBool bAddToEnd = true );
Name | Description | |
---|---|---|
in | pfCompletionCallback | Pointer to the callback function for the CallContext . |
in | oContext | The UserContext associated with this CallContext . |
in | bAddToEnd | If true (the default), the callback is added to the end of the list. If false , it is added to the front of the list. |
Sets the operation to execute when this CallContext
completes.
CompletionCallback
provides an easy and efficient way to ensure that a specific user-specified function is called when the CallContext
completes. By using this callback when methods are called asynchronously, you can eliminate the task of continually polling to check whether the CallContext
has completed.
If more than one callback is registered, by default they are stored and called in the order of registration. The first one to be registered will be the first one to be called. If you want to change this order, you must configure the bAddToEnd parameter when registering certain callbacks.
Do not call NEX blocking functions from inside the callback function.
CONFIDENTIAL