aboutsummaryrefslogtreecommitdiffstats
path: root/library/cpp/logger/composite.h
blob: 47f3558b75b7c8c71e0788cd54514b779be22c33 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#pragma once

#include "backend.h"
#include <util/generic/vector.h>

class TCompositeLogBackend: public TLogBackend {
public:
    virtual void WriteData(const TLogRecord& rec) override;
    virtual void ReopenLog() override;
    virtual void AddLogBackend(THolder<TLogBackend>&& backend);

private:
    TVector<THolder<TLogBackend>> Slaves;
    ELogPriority LogPriority = static_cast<ELogPriority>(0); // has now it's own priority by default
};