ImageGear for C and C++ on Linux v18.8 - Updated
IG_errmngr_callback_get
API Reference Guide > Core Component API Reference > Core Component Functions Reference > Error Functions > IG_errmngr_callback_get

This function obtains error stack callback data and functions that are called to signal error stack changes for all threads.

Declaration:

 
Copy Code
AT_ERRCODE ACCUAPI IG_errmngr_callback_get(
   LPVOID FAR* lplpPrivate,
   LPFNIG_ERRMNGR_ADD FAR* lplpfnAddCB,
   LPFNIG_ERRMNGR_CLEAR FAR* lplpfnClearCB
);

Arguments:

Name Type Description
lplpPrivate LPVOID FAR* Pointer to LPVOID variable to retrieve the private data that is passed to *lplpfnAddCB and *lplpfnClearCB callbacks. NULL is acceptable.
lplpfnAddCB LPFNIG_ERRMNGR_ADD FAR* Pointer to LPFNIG_ERRMNGR_ADD variable to retrieve the callback function that is called after the record is added to the error stack. NULL is acceptable.
lplpfnClearCB LPFNIG_ERRMNGR_CLEAR FAR* Pointer to LPFNIG_ERRMNGR_CLEAR variable to retrieve the callback function that is called after the error stack is cleared. NULL is acceptable.

Return Value:

Returns the code of the ImageGear error that occurred during this function call. A value of zero means no errors have occurred. Errors that occurred during this function call are not appended onto the error stack.

Supported Raster Image Formats:

This function does not process image pixels.

Example:

 
Copy Code
LPVOID Private;
LPFNIG_ERRMNGR_ADD lpfnAdd;
LPFNIG_ERRMNGR_CLEAR lpfnClear;
AT_ERRCODE iErrCode;

iErrCode  = IG_errmngr_callback_get( &Private, &lpfnAdd, &lpfnClear );

Remarks:

Global private data and callback functions can be set using IG_errmngr_callback_set function.

Each thread has its own independent error stack. There are two types of callbacks - local to thread and global. This API allows you to get the global (thread independent) callbacks. Use IG_err_callback_get to get the thread specific data and callbacks.

See Also

IG_errmngr_callback_set