QtPdCom  1.5.2
MessageModel::Impl Class Reference

#include <MessageModelImpl.h>

Inheritance diagram for MessageModel::Impl:
Collaboration diagram for MessageModel::Impl:

Classes

struct  MessageItem

Public Member Functions

 Impl (MessageModel *)
 Constructor.
 ~Impl ()
 Destructor.
void insertItem (MessageItem *)
 Insert a message item.
void addProcessMessage (const PdCom::Message &)
 Called from the PdCom interface, if a new message appears via processMessage() or in context of activeMessagesReply().
void addHistoricMessage (const PdCom::Message &, const PdCom::Message &)
 Called from the PdCom interface, if a historic message appears via getMessageReply().

Static Public Member Functions

static QString wrapText (const QString &, unsigned int=78)
 Returns a wrapped version of a string.

Private Types

typedef QHash< int, Message * > MessageHash
typedef QMap< QString, MessageHashMessageMap
typedef QList< MessageItem * > MessageItemList
typedef QHash< Message::Type, QIcon > IconHash
 Icon hash type.
typedef QHash< Message::Type, QString > IconPathHash
 Icon hash type (with path).

Private Slots

void stateChanged ()
 Reacts on process values changes of all messages to watch.
void processMessage (PdCom::Message message)
void getMessageReply (PdCom::Message message)
void activeMessagesReply (std::vector< PdCom::Message >)
void processReset ()
void reloadActiveMessages ()

Private Member Functions

void getHistoryMessage ()
 Spin up a FutureWatcher and connect its signals.
void announce ()
 Announce next best message as current message.

Private Attributes

MessageModel *const parent
MessageMap messageMap
MessageItemList messageItemList
IconHash iconHash
 Icons for message types.
IconPathHash iconPathHash
 Icons for message types (with path).
MessageItemannouncedMessageItem
 Recently announced message.
QString lang
MessageManagermessageManager
int rowLimit
bool canFetchMore
uint32_t historicSeqNo
bool(* lessThan )(const MessageItem *, const MessageItem *)
QList< PdCom::Message > resetMessagesList
 list of history messages that were reset
Processprocess = nullptr

Friends

class MessageModel
class Message

Member Typedef Documentation

◆ IconHash

typedef QHash<Message::Type, QIcon> QtPdCom::MessageModel::Impl::IconHash
private

Icon hash type.

◆ IconPathHash

typedef QHash<Message::Type, QString> QtPdCom::MessageModel::Impl::IconPathHash
private

Icon hash type (with path).

◆ MessageHash

typedef QHash<int, Message *> QtPdCom::MessageModel::Impl::MessageHash
private

◆ MessageItemList

◆ MessageMap

typedef QMap<QString, MessageHash> QtPdCom::MessageModel::Impl::MessageMap
private

Constructor & Destructor Documentation

◆ Impl()

Constructor.

◆ ~Impl()

Destructor.

Member Function Documentation

◆ activeMessagesReply

void MessageModel::Impl::activeMessagesReply ( std::vector< PdCom::Message > messageList)
privateslot

◆ addHistoricMessage()

void MessageModel::Impl::addHistoricMessage ( const PdCom::Message & pdComMsg,
const PdCom::Message & resetMsg )

Called from the PdCom interface, if a historic message appears via getMessageReply().

◆ addProcessMessage()

void MessageModel::Impl::addProcessMessage ( const PdCom::Message & pdComMsg)

Called from the PdCom interface, if a new message appears via processMessage() or in context of activeMessagesReply().

◆ announce()

void MessageModel::Impl::announce ( )
private

Announce next best message as current message.

◆ getHistoryMessage()

Spin up a FutureWatcher and connect its signals.

◆ getMessageReply

void MessageModel::Impl::getMessageReply ( PdCom::Message message)
privateslot

◆ insertItem()

Insert a message item.

◆ processMessage

void MessageModel::Impl::processMessage ( PdCom::Message message)
privateslot

◆ processReset

void MessageModel::Impl::processReset ( )
privateslot

◆ reloadActiveMessages

◆ stateChanged

void MessageModel::Impl::stateChanged ( )
privateslot

Reacts on process values changes of all messages to watch.

◆ wrapText()

QString MessageModel::Impl::wrapText ( const QString & text,
unsigned int width = 78 )
static

Returns a wrapped version of a string.

◆ Message

friend class Message
friend

◆ MessageModel

friend class MessageModel
friend

Member Data Documentation

◆ announcedMessageItem

Recently announced message.

◆ canFetchMore

◆ historicSeqNo

◆ iconHash

Icons for message types.

See also
Message::Type.

◆ iconPathHash

Icons for message types (with path).

See also
Message::Type.

◆ lang

◆ lessThan

◆ messageItemList

◆ messageManager

◆ messageMap

◆ parent

◆ process

◆ resetMessagesList

QList<PdCom::Message> QtPdCom::MessageModel::Impl::resetMessagesList
private

list of history messages that were reset

◆ rowLimit


The documentation for this class was generated from the following files: