#ifndef LIBREPOMGR_LOGCONTEXT_H #define LIBREPOMGR_LOGCONTEXT_H // Do NOT include this header directly, include "loggin.h" instead. This header only exists to resolve the // cyclic dependency between LogContext and BuildAction but lacks definitions of operator(). #include "./global.h" #include namespace LibRepoMgr { struct BuildAction; struct LIBREPOMGR_EXPORT LogContext { explicit LogContext(BuildAction *buildAction = nullptr); LogContext &operator=(const LogContext &) = delete; template LogContext &operator()(CppUtilities::EscapeCodes::Phrases phrase, Args &&...args); template LogContext &operator()(Args &&...args); template LogContext &operator()(std::string &&msg); private: BuildAction *const m_buildAction; }; inline LogContext::LogContext(BuildAction *buildAction) : m_buildAction(buildAction) { } } // namespace LibRepoMgr #endif // LIBREPOMGR_LOGCONTEXT_H