mirror of
https://github.com/gabime/spdlog.git
synced 2025-03-15 02:29:54 +08:00
20 lines
602 B
C++
20 lines
602 B
C++
#pragma once
|
|
|
|
#include <functional>
|
|
#include "./filename_t.h"
|
|
|
|
namespace spdlog {
|
|
struct file_event_handlers {
|
|
file_event_handlers()
|
|
: before_open(nullptr),
|
|
after_open(nullptr),
|
|
before_close(nullptr),
|
|
after_close(nullptr) {}
|
|
|
|
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;
|
|
std::function<void(const filename_t &filename)> after_close;
|
|
};
|
|
} // namespace spdlog
|