File: typing.h

package info (click to toggle)
libquotient 0.9.5-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 5,588 kB
  • sloc: xml: 39,103; cpp: 25,226; sh: 97; makefile: 10
file content (33 lines) | stat: -rw-r--r-- 1,068 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
// THIS FILE IS GENERATED - ANY EDITS WILL BE OVERWRITTEN

#pragma once

#include <Quotient/jobs/basejob.h>

namespace Quotient {

//! \brief Informs the server that the user has started or stopped typing.
//!
//! This tells the server that the user is typing for the next N
//! milliseconds where N is the value specified in the `timeout` key.
//! Alternatively, if `typing` is `false`, it tells the server that the
//! user has stopped typing.
class QUOTIENT_API SetTypingJob : public BaseJob {
public:
    //! \param userId
    //!   The user who has started to type.
    //!
    //! \param roomId
    //!   The room in which the user is typing.
    //!
    //! \param typing
    //!   Whether the user is typing or not. If `false`, the `timeout`
    //!   key can be omitted.
    //!
    //! \param timeout
    //!   The length of time in milliseconds to mark this user as typing.
    explicit SetTypingJob(const QString& userId, const QString& roomId, bool typing,
                          std::optional<int> timeout = std::nullopt);
};

} // namespace Quotient