You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Instead of dumping everything into the standard error/out streams or disabling logging all together via env vars (setenv("RUST_LOG", "off", true)).
I propose an API similar to the following:
// Adjust for actual usage in the backing code.typedefenum {
WOOTING_LOG_INFO,
WOOTING_LOG_WARNING,
WOOTING_LOG_ERROR,
WOOTING_LOG_FATAL,
} WootingAnalogLogLevel;
typedefvoid (*WootingAnalogLogFunction)(WootingAnalogLogLevellevel, constchar*location, constchar*message, void*user);
/// Sets the logging callback for the analog SDK. Passing `null` sets the logging backend to the default one./// Returns the previous log callback or `null` if none was present.////// This can be called before wooting_analog_initialize,WootingAnalogLogFunctionwooting_analog_log_callback(WootingAnalogLogFunctioncallback, void*user);
Something similar to this should be fairly flexible but at the same time should not change the existing behavior of the library.
(This is related to #42 but I didn't consider it a duplicate)
The text was updated successfully, but these errors were encountered:
Instead of dumping everything into the standard error/out streams or disabling logging all together via env vars (
setenv("RUST_LOG", "off", true)
).I propose an API similar to the following:
Something similar to this should be fairly flexible but at the same time should not change the existing behavior of the library.
(This is related to #42 but I didn't consider it a duplicate)
The text was updated successfully, but these errors were encountered: