|
Infinity Engine v0.6.20
C++ API Documentation
|
Typedefs | |
| using | logging_callback = void(*)(std::string_view) |
| Function pointer type for logging callbacks. | |
Functions | |
| void INFINITY_API_PUBLIC | add_logging_callback (logging_callback callback) |
| Registers a callback function to receive log messages. | |
| void INFINITY_API_PUBLIC | remove_logging_callback (logging_callback callback) |
| Unregisters a previously registered logging callback. | |
Function pointer type for logging callbacks.
Defines the signature for callback functions that receive log messages from the Infinity Engine. Callbacks receive log messages as string views and can process them for display, file output, or forwarding to external logging systems.
| message | The log message as a string_view. |
| void INFINITY_API_PUBLIC Infinity::Logging::add_logging_callback | ( | logging_callback | callback | ) |
Registers a callback function to receive log messages.
Adds a logging callback to the list of active callbacks. When the Infinity Engine generates log messages, all registered callbacks will be invoked with the message content. Multiple callbacks can be registered simultaneously.
| callback | Function pointer to the logging callback to register. |
| void INFINITY_API_PUBLIC Infinity::Logging::remove_logging_callback | ( | logging_callback | callback | ) |
Unregisters a previously registered logging callback.
Removes the specified callback from the list of active callbacks. After removal, the callback will no longer receive log messages from the Infinity Engine.
| callback | Function pointer to the logging callback to unregister. |