API reference
DiagnosticSession
Records a bounded in-memory diagnostic session for a widget tree and optional log messages. UI calls must run on the GUI thread; snapshots exclude widget text and paths, and log messages are only recorded when explicitly enabled.
No matching API members.
fluent::diagnostics::DiagnosticSession
Inherits QObject
Constructors
Properties
bool recording- Read
isRecording()NotifyrecordingChanged()
Methods
bool start(QWidget* root, bool includeLogMessages = false, int maximumDurationMs = 300000)Starts recording for @p root (caller retains ownership); returns false if already recording. A zero @p maximumDurationMs records until stop() is called; positive values stop automatically after that many milliseconds.
void stop()Stops recording and captures a final widget snapshot.
void clear()Stops recording and discards all collected data.
QVariantMap report() constReturns the collected JSON inspection report as a QVariantMap.
QVariantMap captureReport()Captures a JSON inspection report of the current widget state without stopping the session (GUI thread only).
static QByteArray createBundle(const QVariantMap& report, const QVariantMap& attachments = {})Packages report.json and optional attachments into an in-memory ZIP archive (up to 20 MiB). Returns an empty byte array if any attachment name is invalid or the size limit is exceeded.
static QVariantMap environment()Returns safe runtime environment metadata without host names or file paths.
void recordMessage(QtMsgType type, const QString& category, const QString& message)Records a log message; safe to call from worker threads while this session is alive.
MessageSink messageSink() constReturns a thread-safe log callback that becomes a no-op after the session is destroyed.
Signals
Types and aliases
Destructors
Protected members
Methods
Qt base class docs: QObject