mirror of
https://github.com/Palm1r/QodeAssist.git
synced 2026-07-21 10:40:57 -04:00
refactor: Restructure project into sources/tests layout and dissolve PluginLLMCore
This commit is contained in:
26
sources/logger/RequestPerformanceLogger.hpp
Normal file
26
sources/logger/RequestPerformanceLogger.hpp
Normal file
@@ -0,0 +1,26 @@
|
||||
// Copyright (C) 2025 Povilas Kanapickas <povilas@radix.lt>
|
||||
// SPDX-License-Identifier: GPL-3.0-or-later
|
||||
// Additional attribution terms under GPLv3 §7(b) apply — see LICENSE
|
||||
|
||||
#include "IRequestPerformanceLogger.hpp"
|
||||
#include <QDateTime>
|
||||
#include <QMap>
|
||||
|
||||
namespace QodeAssist {
|
||||
|
||||
class RequestPerformanceLogger : public IRequestPerformanceLogger
|
||||
{
|
||||
public:
|
||||
RequestPerformanceLogger() = default;
|
||||
~RequestPerformanceLogger() override = default;
|
||||
|
||||
void startTimeMeasurement(const QString &requestId) override;
|
||||
void endTimeMeasurement(const QString &requestId) override;
|
||||
void logPerformance(const QString &requestId, qint64 elapsedMs) override;
|
||||
void logPerformance(const QString &requestId, const QString &operation, qint64 elapsedMs);
|
||||
|
||||
private:
|
||||
QMap<QString, qint64> m_requestStartTimes;
|
||||
};
|
||||
|
||||
} // namespace QodeAssist
|
||||
Reference in New Issue
Block a user