Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
qqmlprofilerqtdwriter_p.h
Go to the documentation of this file.
1// Copyright (C) 2025 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3// Qt-Security score:significant
4
5#ifndef QQMLPROFILERQTDWRITER_P_H
6#define QQMLPROFILERQTDWRITER_P_H
7
8//
9// W A R N I N G
10// -------------
11//
12// This file is not part of the Qt API. It exists purely as an
13// implementation detail. This header file may change from version to
14// version without notice, or even be removed.
15//
16// We mean it.
17//
18
19#include <private/qqmlprofilerclientdefinitions_p.h>
20#include <private/qqmlprofilereventlocation_p.h>
21#include <private/qqmlprofilereventreceiver_p.h>
22
23#include <QObject>
24
25QT_BEGIN_NAMESPACE
26
27class QQmlProfilerQtdWriterPrivate;
29{
30 Q_OBJECT
31 Q_DECLARE_PRIVATE(QQmlProfilerQtdWriter)
32public:
33 explicit QQmlProfilerQtdWriter(QObject *parent = nullptr);
35
36 int numLoadedEventTypes() const final;
37 void addEventType(const QQmlProfilerEventType &type) final;
38 void addEvent(const QQmlProfilerEvent &event) final;
39 bool save(const QString &filename) final;
40 bool isEmpty() const final;
41 void clear() final;
42
43 void startTrace(qint64 time, const QList<int> &engineIds) final;
44 void endTrace(qint64 time, const QList<int> &engineIds) final;
45 void complete(qint64 maximumTime) final;
46};
47
48QT_END_NAMESPACE
49
50#endif // QQMLPROFILERQTDWRITER_P_H
QVector< QQmlProfilerEvent > events
QVector< QQmlProfilerEventType > eventTypes
void addEvent(const QQmlProfilerEvent &event) final
void complete(qint64 maximumTime) final
void endTrace(qint64 time, const QList< int > &engineIds) final
bool save(const QString &filename) final
void addEventType(const QQmlProfilerEventType &type) final
int numLoadedEventTypes() const final
void startTrace(qint64 time, const QList< int > &engineIds) final
static const char * MESSAGE_STRINGS[]
static const char * RANGE_TYPE_STRINGS[]
static QString qmlRangeTypeAsString(RangeType type)
bool compareStartTimes(const QQmlProfilerEvent &t1, const QQmlProfilerEvent &t2)
const char PROFILER_FILE_VERSION[]
static QString qmlMessageAsString(Message type)
Q_STATIC_ASSERT(sizeof(SharedImageHeader) % 4==0)
DataIterator(const QQmlProfilerQtdWriterPrivate *d, qxp::function_ref< void(const QQmlProfilerEvent &, qint64)> &&sendEvent)
void writeStartElement(const char *name)
StreamWriter(const QString &filename)
void writeAttribute(const char *name, Number number)
void writeAttribute(const char *name, const char *value)
void writeTextElement(const char *name, Number number)
void writeTextElement(const char *name, const char *value)
void writeAttribute(const char *name, const QQmlProfilerEvent &event, int i, bool printZero=true)
void writeTextElement(const char *name, const QString &value)