aboutsummaryrefslogtreecommitdiff
path: root/lib/csapi/typing.cpp
blob: 21bd45aec2d41662df537ae51f62a4af5aab0194 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
/******************************************************************************
 * THIS FILE IS GENERATED - ANY EDITS WILL BE OVERWRITTEN
 */

#include "typing.h"

using namespace Quotient;

SetTypingJob::SetTypingJob(const QString& userId, const QString& roomId,
                           bool typing, Omittable<int> timeout)
    : BaseJob(HttpVerb::Put, QStringLiteral("SetTypingJob"),
              makePath("/_matrix/client/v3", "/rooms/", roomId, "/typing/",
                       userId))
{
    QJsonObject _dataJson;
    addParam<>(_dataJson, QStringLiteral("typing"), typing);
    addParam<IfNotEmpty>(_dataJson, QStringLiteral("timeout"), timeout);
    setRequestData({ _dataJson });
}