mirror of
https://github.com/gabime/spdlog.git
synced 2025-01-24 06:32:06 +08:00
Add default file-event_handler callbacks. #2374
This commit is contained in:
parent
128cbe5a06
commit
d89a1e66d8
@ -306,6 +306,13 @@ struct source_loc
|
||||
|
||||
struct file_event_handlers
|
||||
{
|
||||
file_event_handlers()
|
||||
: before_open([](spdlog::filename_t) {})
|
||||
, after_open ([](spdlog::filename_t, std::FILE*) {})
|
||||
, before_close([](spdlog::filename_t, std::FILE*) {})
|
||||
, after_close([](spdlog::filename_t) {})
|
||||
{}
|
||||
|
||||
std::function<void(const filename_t &filename)> before_open;
|
||||
std::function<void(const filename_t &filename, std::FILE *file_stream)> after_open;
|
||||
std::function<void(const filename_t &filename, std::FILE *file_stream)> before_close;
|
||||
|
Loading…
Reference in New Issue
Block a user