diff options
author | Matt Ranostay <matt.ranostay@konsulko.com> | 2018-05-01 23:15:58 -0700 |
---|---|---|
committer | Matt Ranostay <matt.ranostay@konsulko.com> | 2018-05-13 17:43:33 -0700 |
commit | bb1aee701bc3516c2072a79d3129ee83918df7fd (patch) | |
tree | 150edc50142429ee566edf629a8d3f5dfb3a8557 /message.h | |
parent | 6465961f28f40ff5a2da31876f1c23ea3c7f7cec (diff) |
message: add response message support
Add support for callid sequencing, and request data being included
with the response message.
Bug-AGL: SPEC-1404
Change-Id: I259ae3da68e55de17eafe9db534258db5fbc3ef8
Signed-off-by: Matt Ranostay <matt.ranostay@konsulko.com>
Diffstat (limited to 'message.h')
-rw-r--r-- | message.h | 10 |
1 files changed, 8 insertions, 2 deletions
@@ -18,7 +18,8 @@ #define MESSAGE_H #include <QObject> -#include <QJsonArray> +#include <QMap> +#include <QVariant> #include <QJsonDocument> #include <QJsonObject> @@ -31,6 +32,7 @@ enum MessageId { enum MessageType { GenericMessage, + ResponseRequestMessage, TelephonyEventMessage, WeatherEventMessage, MediaplayerEventMessage, @@ -90,10 +92,14 @@ class Message : public QObject return m_init; } + inline void setCallId(qint32 callId) { + m_request["callid"] = callId; + } + protected: bool m_event, m_init, m_reply; QString m_event_api, m_event_name, m_reply_info, m_reply_status, m_reply_uuid; - QJsonArray m_request; + QMap<QString, QVariant> m_request; QJsonDocument m_jdoc; QJsonObject m_event_data, m_reply_data; }; |