Logger Class

Installs a qt messageHandler and receives all log messages. More...

Header: #include <Logger>
Inherits: QObject
Inherited By:


Public Functions

Logger(QObject *parent = 0)
virtual ~Logger()

Public Slots

void setIgnoreMessages(bool ignoreMessages)


void message(int type, const QString &msg, const QUrl &url = QUrl(), int line = -1, int column = -1)

Detailed Description

The intention is to use this class if you want to display the log into widget or you want to preproccess the log messages itself before displaying it

See also RemoteLogger.

Member Function Documentation

Logger::Logger(QObject *parent = 0)

Standard constructor using parent as parent

[signal] void Logger::message(int type, const QString &msg, const QUrl &url = QUrl(), int line = -1, int column = -1)

Emitted for every incoming log message type describes the type of the log message (QtMsgType), msg is the debug message, url is the document location, line and column is the position in the document. This signal will not be emitted when ignoreMessages set to true

See also setIgnoreMessages().

[static slot] void Logger::setIgnoreMessages(bool ignoreMessages)

When ignoreMessages set to true, the Logger ignores all incoming log messages

[virtual] Logger::~Logger()

Standard destructor

© 2019 Luxoft Sweden AB. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.