1 #ifndef TGBOT_LOGGER_FACILITY_H 2 #define TGBOT_LOGGER_FACILITY_H 14 std::ostream *stream{&std::cout};
15 std::string dateFormat{
"%Y/%m/%d %H:%M:%S"};
36 void info(std::string
const &logInfo)
const;
42 void error(std::string
const &logError)
const;
48 explicit operator bool()
const;
55 inline void setStream(std::ostream &newStream) { stream = &newStream; }
62 dateFormat = std::move(newDateFormat);
67 #endif // TGBOT_LOGGER_FACILITY_H void error(std::string const &logError) const
log some error...
Main tgbot namespace.
Definition: bot.h:13
void setDateFormat(std::string &newDateFormat)
set new date format, default is: "%Y/%m/%d %H:%M:%S"
Definition: logger.h:61
Logging facility for telegram-bot-api, see also: tgbot::methods::Api::getLogger() ...
Definition: logger.h:12
void info(std::string const &logInfo) const
log some info...
void setStream(std::ostream &newStream)
set new stream
Definition: logger.h:55