aboutsummaryrefslogtreecommitdiff
path: root/lib/csapi/definitions/client_device.cpp
diff options
context:
space:
mode:
authorKitsune Ral <Kitsune-Ral@users.sf.net>2020-06-09 08:52:25 +0200
committerGitHub <noreply@github.com>2020-06-09 08:52:25 +0200
commit370d9b3e46332d38df8798cda208c534c58be808 (patch)
treef3db0cd7463468ff52c74446acd608356f8b8ab6 /lib/csapi/definitions/client_device.cpp
parente1f5d0aa2c33e6da6c3a609c8bc7e0b5867e748d (diff)
parent10d9ac4673e374a9ac17ff492591136520337c4c (diff)
downloadlibquotient-370d9b3e46332d38df8798cda208c534c58be808.tar.gz
libquotient-370d9b3e46332d38df8798cda208c534c58be808.zip
Merge pull request #405 from quotient-im/kitsune-basejob-store-json-response
Store JSON response in BaseJob + tweaks to the generated code
Diffstat (limited to 'lib/csapi/definitions/client_device.cpp')
-rw-r--r--lib/csapi/definitions/client_device.cpp23
1 files changed, 0 insertions, 23 deletions
diff --git a/lib/csapi/definitions/client_device.cpp b/lib/csapi/definitions/client_device.cpp
deleted file mode 100644
index 09544138..00000000
--- a/lib/csapi/definitions/client_device.cpp
+++ /dev/null
@@ -1,23 +0,0 @@
-/******************************************************************************
- * THIS FILE IS GENERATED - ANY EDITS WILL BE OVERWRITTEN
- */
-
-#include "client_device.h"
-
-using namespace Quotient;
-
-void JsonObjectConverter<Device>::dumpTo(QJsonObject& jo, const Device& pod)
-{
- addParam<>(jo, QStringLiteral("device_id"), pod.deviceId);
- addParam<IfNotEmpty>(jo, QStringLiteral("display_name"), pod.displayName);
- addParam<IfNotEmpty>(jo, QStringLiteral("last_seen_ip"), pod.lastSeenIp);
- addParam<IfNotEmpty>(jo, QStringLiteral("last_seen_ts"), pod.lastSeenTs);
-}
-
-void JsonObjectConverter<Device>::fillFrom(const QJsonObject& jo, Device& result)
-{
- fromJson(jo.value("device_id"_ls), result.deviceId);
- fromJson(jo.value("display_name"_ls), result.displayName);
- fromJson(jo.value("last_seen_ip"_ls), result.lastSeenIp);
- fromJson(jo.value("last_seen_ts"_ls), result.lastSeenTs);
-}