|
QGroundControl
Ground Control Station for MAVLink Drones
|
#include <LogEntry.h>
Public Types | |
| enum | Role { TimestampRole = Qt::UserRole + 1 , LevelRole , LevelLabelRole , CategoryRole , MessageRole , FormattedRole , FileRole , FunctionRole , LineRole , ThreadIdRole } |
| enum | Column { TimestampColumn = 0 , LevelColumn , CategoryColumn , SourceColumn , MessageColumn , ColumnCount } |
Public Member Functions | |
| QML_ANONYMOUS(QDateTime timestamp MEMBER timestamp FINAL) 1(Level level MEMBER level FINAL) 1(QString category MEMBER category FINAL) 1(QString message MEMBER message FINAL) 1(QString file MEMBER file FINAL) 1(QString function MEMBER function FINAL) 1(QString formatted MEMBER formatted FINAL) 1(int line MEMBER line FINAL) public | LogEntry ()=default |
| LogEntry (const LogEntry &)=default | |
| LogEntry (LogEntry &&) noexcept=default | |
| LogEntry & | operator= (const LogEntry &)=default |
| LogEntry & | operator= (LogEntry &&) noexcept=default |
| QString | levelLabel () const |
| void | buildFormatted () |
| QVariant | roleData (int role) const |
| QVariant | columnDisplayData (int column) const |
Static Public Member Functions | |
| static Level | fromQtMsgType (QtMsgType type) |
| static QHash< int, QByteArray > | roleNames () |
| static QVariant | columnHeaderData (int section) |
Public Attributes | |
| QDateTime | timestamp |
| Level | level = Debug |
| QString | category |
| QString | message |
| QString | file |
| QString | function |
| QString | formatted |
| Qt::HANDLE | threadId = nullptr |
| int | line = 0 |
Definition at line 7 of file LogEntry.h.
| enum LogEntry::Column |
| Enumerator | |
|---|---|
| TimestampColumn | |
| LevelColumn | |
| CategoryColumn | |
| SourceColumn | |
| MessageColumn | |
| ColumnCount | |
Definition at line 66 of file LogEntry.h.
| enum LogEntry::Role |
| Enumerator | |
|---|---|
| TimestampRole | |
| LevelRole | |
| LevelLabelRole | |
| CategoryRole | |
| MessageRole | |
| FormattedRole | |
| FileRole | |
| FunctionRole | |
| LineRole | |
| ThreadIdRole | |
Definition at line 52 of file LogEntry.h.
|
default |
|
default |
|
defaultnoexcept |
| void LogEntry::buildFormatted | ( | ) |
Definition at line 23 of file LogEntry.cc.
References category, formatted, levelLabel(), message, and timestamp.
| QVariant LogEntry::columnDisplayData | ( | int | column | ) | const |
Definition at line 91 of file LogEntry.cc.
References category, CategoryColumn, ColumnCount, file, LevelColumn, levelLabel(), line, message, MessageColumn, SourceColumn, timestamp, and TimestampColumn.
Referenced by LogEntryTableModel::data(), and LogEntryTableModel::multiData().
|
static |
Definition at line 113 of file LogEntry.cc.
References CategoryColumn, ColumnCount, LevelColumn, MessageColumn, SourceColumn, and TimestampColumn.
Referenced by LogEntryTableModel::headerData().
|
static |
Definition at line 29 of file LogEntry.cc.
| QString LogEntry::levelLabel | ( | ) | const |
Definition at line 7 of file LogEntry.cc.
References level.
Referenced by buildFormatted(), columnDisplayData(), LogFormatter::entryToJson(), LogFormatter::formatCsvRow(), and roleData().
| QVariant LogEntry::roleData | ( | int | role | ) | const |
Definition at line 64 of file LogEntry.cc.
References category, CategoryRole, file, FileRole, formatted, FormattedRole, function, FunctionRole, level, levelLabel(), LevelLabelRole, LevelRole, line, LineRole, message, MessageRole, threadId, ThreadIdRole, timestamp, and TimestampRole.
Referenced by LogEntryTableModel::data(), and LogEntryTableModel::multiData().
|
static |
Definition at line 46 of file LogEntry.cc.
References CategoryRole, FileRole, FormattedRole, FunctionRole, LevelLabelRole, LevelRole, LineRole, MessageRole, ThreadIdRole, and TimestampRole.
Referenced by LogEntryTableModel::roleNames().
| QString LogEntry::category |
Definition at line 39 of file LogEntry.h.
Referenced by buildFormatted(), columnDisplayData(), LogFormatter::entryToJson(), LogFormatter::formatCsvRow(), and roleData().
| QString LogEntry::file |
Definition at line 41 of file LogEntry.h.
Referenced by columnDisplayData(), and roleData().
| QString LogEntry::formatted |
Definition at line 43 of file LogEntry.h.
Referenced by buildFormatted(), and roleData().
| QString LogEntry::function |
Definition at line 42 of file LogEntry.h.
Referenced by roleData().
| Level LogEntry::level = Debug |
Definition at line 38 of file LogEntry.h.
Referenced by LogFormatter::entryToJson(), levelLabel(), and roleData().
| int LogEntry::line = 0 |
Definition at line 45 of file LogEntry.h.
Referenced by columnDisplayData(), and roleData().
| QString LogEntry::message |
Definition at line 40 of file LogEntry.h.
Referenced by buildFormatted(), columnDisplayData(), LogFormatter::entryToJson(), LogFormatter::formatCsvRow(), and roleData().
| Qt::HANDLE LogEntry::threadId = nullptr |
Definition at line 44 of file LogEntry.h.
Referenced by roleData().
| QDateTime LogEntry::timestamp |
Definition at line 37 of file LogEntry.h.
Referenced by buildFormatted(), columnDisplayData(), LogFormatter::entryToJson(), LogFormatter::formatCsvRow(), and roleData().