#ifndef JSONPARSER #define JSONPARSER #include "include/parser/IParser.h" #include class JsonParser : public IParser { public: Log_ptr parse(const QString& input) const override; private: QJsonObject parseJson(const QString& input) const; std::optional extractId(const QJsonValue& value) const; std::optional extractLevel(const QJsonValue& value) const; std::optional extractSource(const QJsonValue& value) const; std::optional > extractMessages(const QJsonValue& value) const; std::optional extractScope(const QJsonValue& value) const; std::optional extractThreadId(const QJsonValue& value) const; std::optional extractTimestamp(const QJsonValue& value) const; std::optional parseMessage(const QJsonValue& value) const; }; #endif //JSONPARSER