25 lines
728 B
C++
25 lines
728 B
C++
#ifndef ILOG_MAKE_PTR_H
|
|
#define ILOG_MAKE_PTR_H
|
|
#include "ILog.h"
|
|
#include "Log.h"
|
|
#include <iostream>
|
|
#include <memory>
|
|
class ILogMakePtr
|
|
{
|
|
public:
|
|
static std::shared_ptr<ILogMakePtr> &GetInstance(std::shared_ptr<ILogMakePtr> *impl = nullptr)
|
|
{
|
|
static std::shared_ptr<ILogMakePtr> instance = std::make_shared<ILogMakePtr>();
|
|
if (impl)
|
|
{
|
|
instance = *impl;
|
|
}
|
|
return instance;
|
|
}
|
|
ILogMakePtr() = default;
|
|
virtual ~ILogMakePtr() = default;
|
|
virtual std::shared_ptr<ILog> MakeLogImplPtr();
|
|
virtual std::shared_ptr<ILog> MakeLogEasylogging(const LogSetting *setting);
|
|
virtual std::shared_ptr<ILog> MakeLongCapture(const LogSetting *setting);
|
|
};
|
|
#endif |