Open Inventor Release 2024.2.0
 
Loading...
Searching...
No Matches
A.3. Handling an Error

You can override the default error handler by specifying a callback function to be invoked when an error is posted. Each subclass of SoError supports a static setHandlerCallback() method. You can register the callback on SoError, so that it is called for all errors, or you can register it on one of the classes derived from SoError. The callback for the most derived class of a specific error instance is used to handle the error. Note that the error instance passed to a callback is deleted immediately after the callback is invoked. The application must copy this data ahead of time if it needs to use it later.