diff options
author | Hop311 <Hop3114@gmail.com> | 2023-05-04 15:47:20 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-05-04 15:47:20 +0200 |
commit | 7791a18094efaf62377606a7e5a7cba85a4c7a64 (patch) | |
tree | cd3ebcae0f67b07488fadb31ba3b376b306e03f6 /extension/src/openvic2/Logger.cpp | |
parent | 6fd8fc3a786370207508631e569c1e8f5ab0e4e3 (diff) | |
parent | 2420f8b8fdd2db84e053ebb2d7f6e4840171009e (diff) |
Merge pull request #106 from OpenVic2Project/simulation-submodule
Moved simulation code to separate submodule
Diffstat (limited to 'extension/src/openvic2/Logger.cpp')
-rw-r--r-- | extension/src/openvic2/Logger.cpp | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/extension/src/openvic2/Logger.cpp b/extension/src/openvic2/Logger.cpp deleted file mode 100644 index 4d7378e..0000000 --- a/extension/src/openvic2/Logger.cpp +++ /dev/null @@ -1,26 +0,0 @@ -#include "Logger.hpp" - -#include <iostream> - -using namespace OpenVic2; - -Logger::log_func_t Logger::info_func = [](std::string&& str) { std::cout << str; }; -Logger::log_func_t Logger::error_func = [](std::string&& str) { std::cerr << str; }; - -char const* Logger::get_filename(char const* filepath) { - if (filepath == nullptr) return nullptr; - char const* last_slash = filepath; - while (*filepath != '\0') { - if (*filepath == '\\' || *filepath == '/') last_slash = filepath + 1; - filepath++; - } - return last_slash; -} - -void Logger::set_info_func(log_func_t log_func) { - info_func = log_func; -} - -void Logger::set_error_func(log_func_t log_func) { - error_func = log_func; -} |