gr application register log cb

#include <gre/gre.h>
int gr_application_register_log_cb(
  gr_application_t *app, 
  gr_log_writer_cb_t cb, 
  void *udata, 
  gr_log_writer_cb_t *old_cb, 
  void **old_udata   
);

The gr_application_register_log_cb function will register a handler with the application that will be called when a log message is generated.

            Parameters:
    app        A pointer to the application handle created using gr_application_create_args.
    cb         The function that should be called to when a log message is generated. 
    udata      User data that will be passed to the handler when the log message is sent.
    old_cb     Storage for the previous log callback.  This can be NULL. 
    old_udata  Storage for the previous user data.  This can be NULL. 

Returns:
    0 if the registeration is a sucess and -1 if the registration fails.

The gr_application_register_log_cb provides a way for user code to register a function that will be called when a log message is generated by the engine.

Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request

Comments

0 comments

Article is closed for comments.