blob: bf3be10f85100a78287e50ba380a79d33c46b125 [file] [log] [blame]
#ifndef CASBIN_CPP_LOG_LOGGER
#define CASBIN_CPP_LOG_LOGGER
#include <string>
namespace casbin {
class Logger {
protected:
bool m_enable;
public:
// EnableLog controls whether print the message.
virtual void EnableLog(bool enable) = 0;
// IsEnabled returns if logger is enabled.
virtual bool IsEnabled() = 0;
// Print formats using the default formats for its operands and logs the message.
template <typename T, typename... Object>
void Print(T arg, Object... objects);
// Printf formats according to a format specifier and logs the message.
template <typename... Object>
void Printf(std::string, Object... objects);
};
} // namespace casbin
#endif