diff options
author | Kitsune Ral <Kitsune-Ral@users.sf.net> | 2018-12-13 07:47:58 +0900 |
---|---|---|
committer | Kitsune Ral <Kitsune-Ral@users.sf.net> | 2018-12-13 07:47:58 +0900 |
commit | 8dcda23ed210151904c9137067626eddae683822 (patch) | |
tree | 49328653d31d6dd68cd888e7aa7c121d48daf4cf /lib/csapi/definitions | |
parent | 5b06b165ba2adec50099452bcf4c5f20009423ad (diff) | |
download | libquotient-8dcda23ed210151904c9137067626eddae683822.tar.gz libquotient-8dcda23ed210151904c9137067626eddae683822.zip |
Regenerate csapi/
Diffstat (limited to 'lib/csapi/definitions')
-rw-r--r-- | lib/csapi/definitions/push_rule.h | 4 | ||||
-rw-r--r-- | lib/csapi/definitions/room_event_filter.cpp | 6 | ||||
-rw-r--r-- | lib/csapi/definitions/room_event_filter.h | 8 | ||||
-rw-r--r-- | lib/csapi/definitions/sync_filter.h | 2 |
4 files changed, 5 insertions, 15 deletions
diff --git a/lib/csapi/definitions/push_rule.h b/lib/csapi/definitions/push_rule.h index 5f52876d..2ab68cb1 100644 --- a/lib/csapi/definitions/push_rule.h +++ b/lib/csapi/definitions/push_rule.h @@ -7,10 +7,10 @@ #include "converters.h" #include "csapi/definitions/push_condition.h" -#include "converters.h" +#include <QtCore/QJsonObject> #include <QtCore/QVector> #include <QtCore/QVariant> -#include <QtCore/QJsonObject> +#include "converters.h" namespace QMatrixClient { diff --git a/lib/csapi/definitions/room_event_filter.cpp b/lib/csapi/definitions/room_event_filter.cpp index 8cd2ded7..f6f1e5cb 100644 --- a/lib/csapi/definitions/room_event_filter.cpp +++ b/lib/csapi/definitions/room_event_filter.cpp @@ -12,8 +12,6 @@ QJsonObject QMatrixClient::toJson(const RoomEventFilter& pod) addParam<IfNotEmpty>(jo, QStringLiteral("not_rooms"), pod.notRooms); addParam<IfNotEmpty>(jo, QStringLiteral("rooms"), pod.rooms); addParam<IfNotEmpty>(jo, QStringLiteral("contains_url"), pod.containsUrl); - addParam<IfNotEmpty>(jo, QStringLiteral("lazy_load_members"), pod.lazyLoadMembers); - addParam<IfNotEmpty>(jo, QStringLiteral("include_redundant_members"), pod.includeRedundantMembers); return jo; } @@ -26,10 +24,6 @@ RoomEventFilter FromJsonObject<RoomEventFilter>::operator()(const QJsonObject& j fromJson<QStringList>(jo.value("rooms"_ls)); result.containsUrl = fromJson<bool>(jo.value("contains_url"_ls)); - result.lazyLoadMembers = - fromJson<bool>(jo.value("lazy_load_members"_ls)); - result.includeRedundantMembers = - fromJson<bool>(jo.value("include_redundant_members"_ls)); return result; } diff --git a/lib/csapi/definitions/room_event_filter.h b/lib/csapi/definitions/room_event_filter.h index 87f01189..00f1e1fb 100644 --- a/lib/csapi/definitions/room_event_filter.h +++ b/lib/csapi/definitions/room_event_filter.h @@ -19,12 +19,8 @@ namespace QMatrixClient QStringList notRooms; /// A list of room IDs to include. If this list is absent then all rooms are included. QStringList rooms; - /// If ``true``, includes only events with a ``url`` key in their content. If ``false``, excludes those events. Defaults to ``false``. - bool containsUrl; - /// If ``true``, the only ``m.room.member`` events returned in the ``state`` section of the ``/sync`` response are those which are definitely necessary for a client to display the ``sender`` of the timeline events in that response. If ``false``, ``m.room.member`` events are not filtered. By default, servers should suppress duplicate redundant lazy-loaded ``m.room.member`` events from being sent to a given client across multiple calls to ``/sync``, given that most clients cache membership events (see include_redundant_members to change this behaviour). - bool lazyLoadMembers; - /// If ``true``, the ``state`` section of the ``/sync`` response will always contain the ``m.room.member`` events required to display the ``sender`` of the timeline events in that response, assuming ``lazy_load_members`` is enabled. This means that redundant duplicate member events may be returned across multiple calls to ``/sync``. This is useful for naive clients who never track membership data. If ``false``, duplicate ``m.room.member`` events may be suppressed by the server across multiple calls to ``/sync``. If ``lazy_load_members`` is ``false`` this field is ignored. - bool includeRedundantMembers; + /// If ``true``, includes only events with a ``url`` key in their content. If ``false``, excludes those events. If omitted, ``url`` key is not considered for filtering. + Omittable<bool> containsUrl; }; QJsonObject toJson(const RoomEventFilter& pod); diff --git a/lib/csapi/definitions/sync_filter.h b/lib/csapi/definitions/sync_filter.h index ca275a9a..592038dc 100644 --- a/lib/csapi/definitions/sync_filter.h +++ b/lib/csapi/definitions/sync_filter.h @@ -24,7 +24,7 @@ namespace QMatrixClient /// The events that aren't recorded in the room history, e.g. typing and receipts, to include for rooms. Omittable<RoomEventFilter> ephemeral; /// Include rooms that the user has left in the sync, default false - bool includeLeave; + Omittable<bool> includeLeave; /// The state events to include for rooms. Omittable<RoomEventFilter> state; /// The message and state update events to include for rooms. |