From aacc4bcb4a487871daae6717f77605aaba444341 Mon Sep 17 00:00:00 2001 From: Marc Deop Date: Sat, 2 Mar 2019 12:26:57 +0100 Subject: style: apply .clang-format to all .cpp and .h files --- lib/csapi/redaction.h | 51 +++++++++++++++++++++++++-------------------------- 1 file changed, 25 insertions(+), 26 deletions(-) (limited to 'lib/csapi/redaction.h') diff --git a/lib/csapi/redaction.h b/lib/csapi/redaction.h index d02abfd0..ab235b31 100644 --- a/lib/csapi/redaction.h +++ b/lib/csapi/redaction.h @@ -6,48 +6,47 @@ #include "jobs/basejob.h" - -namespace QMatrixClient -{ +namespace QMatrixClient { // Operations /// Strips all non-integrity-critical information out of an event. /// /// Strips all information out of an event which isn't critical to the /// integrity of the server-side representation of the room. - /// + /// /// This cannot be undone. - /// + /// /// Users may redact their own events, and any user with a power level /// greater than or equal to the `redact` power level of the room may /// redact events there. class RedactEventJob : public BaseJob { public: - /*! Strips all non-integrity-critical information out of an event. - * \param roomId - * The room from which to redact the event. - * \param eventId - * The ID of the event to redact - * \param txnId - * The transaction ID for this event. Clients should generate a - * unique ID; it will be used by the server to ensure idempotency of requests. - * \param reason - * The reason for the event being redacted. - */ - explicit RedactEventJob(const QString& roomId, const QString& eventId, const QString& txnId, const QString& reason = {}); - ~RedactEventJob() override; - - // Result properties - - /// A unique identifier for the event. - const QString& eventId() const; + /*! Strips all non-integrity-critical information out of an event. + * \param roomId + * The room from which to redact the event. + * \param eventId + * The ID of the event to redact + * \param txnId + * The transaction ID for this event. Clients should generate a + * unique ID; it will be used by the server to ensure idempotency of + * requests. \param reason The reason for the event being redacted. + */ + explicit RedactEventJob(const QString& roomId, const QString& eventId, + const QString& txnId, + const QString& reason = {}); + ~RedactEventJob() override; + + // Result properties + + /// A unique identifier for the event. + const QString& eventId() const; protected: - Status parseJson(const QJsonDocument& data) override; + Status parseJson(const QJsonDocument& data) override; private: - class Private; - QScopedPointer d; + class Private; + QScopedPointer d; }; } // namespace QMatrixClient -- cgit v1.2.3 From 27ca32a1e5a56e09b9cc1d94224d2831004dcf3d Mon Sep 17 00:00:00 2001 From: Kitsune Ral Date: Sun, 7 Jul 2019 19:32:34 +0900 Subject: Namespace: QMatrixClient -> Quotient (with back comp alias) --- lib/csapi/redaction.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/csapi/redaction.h') diff --git a/lib/csapi/redaction.h b/lib/csapi/redaction.h index c75421cb..42022930 100644 --- a/lib/csapi/redaction.h +++ b/lib/csapi/redaction.h @@ -6,7 +6,7 @@ #include "jobs/basejob.h" -namespace QMatrixClient +namespace Quotient { // Operations @@ -53,4 +53,4 @@ private: QScopedPointer d; }; -} // namespace QMatrixClient +} // namespace Quotient -- cgit v1.2.3 From 7036ed0dcb137cb5cbb6b426dd338c5e2e4c6424 Mon Sep 17 00:00:00 2001 From: Kitsune Ral Date: Fri, 17 Apr 2020 07:42:13 +0200 Subject: Regenerate API files using new GTAD and refreshed templates No functional changes. --- lib/csapi/redaction.h | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'lib/csapi/redaction.h') diff --git a/lib/csapi/redaction.h b/lib/csapi/redaction.h index 42022930..0e9095d1 100644 --- a/lib/csapi/redaction.h +++ b/lib/csapi/redaction.h @@ -6,13 +6,12 @@ #include "jobs/basejob.h" -namespace Quotient -{ +namespace Quotient { // Operations -/// Strips all non-integrity-critical information out of an event. -/*! +/*! \brief Strips all non-integrity-critical information out of an event. + * * Strips all information out of an event which isn't critical to the * integrity of the server-side representation of the room. * @@ -22,10 +21,10 @@ namespace Quotient * greater than or equal to the `redact` power level of the room may * redact events there. */ -class RedactEventJob : public BaseJob -{ +class RedactEventJob : public BaseJob { public: - /*! Strips all non-integrity-critical information out of an event. + /*! \brief Strips all non-integrity-critical information out of an event. + * * \param roomId * The room from which to redact the event. * \param eventId -- cgit v1.2.3 From 32729d9a7519cd2c4cddb0174b8329c6fd4a4a83 Mon Sep 17 00:00:00 2001 From: Kitsune Ral Date: Sun, 7 Jun 2020 19:46:40 +0200 Subject: Update generated files according to gtad/* changes --- lib/csapi/redaction.h | 23 +++++++++-------------- 1 file changed, 9 insertions(+), 14 deletions(-) (limited to 'lib/csapi/redaction.h') diff --git a/lib/csapi/redaction.h b/lib/csapi/redaction.h index 0e9095d1..c737de41 100644 --- a/lib/csapi/redaction.h +++ b/lib/csapi/redaction.h @@ -8,8 +8,6 @@ namespace Quotient { -// Operations - /*! \brief Strips all non-integrity-critical information out of an event. * * Strips all information out of an event which isn't critical to the @@ -18,38 +16,35 @@ namespace Quotient { * This cannot be undone. * * Users may redact their own events, and any user with a power level - * greater than or equal to the `redact` power level of the room may + * greater than or equal to the ``redact`` power level of the room may * redact events there. */ class RedactEventJob : public BaseJob { public: /*! \brief Strips all non-integrity-critical information out of an event. + * * * \param roomId * The room from which to redact the event. + * * \param eventId * The ID of the event to redact + * * \param txnId * The transaction ID for this event. Clients should generate a * unique ID; it will be used by the server to ensure idempotency of - * requests. \param reason The reason for the event being redacted. + * requests. + * + * \param reason + * The reason for the event being redacted. */ explicit RedactEventJob(const QString& roomId, const QString& eventId, const QString& txnId, const QString& reason = {}); - ~RedactEventJob() override; - // Result properties /// A unique identifier for the event. - const QString& eventId() const; - -protected: - Status parseJson(const QJsonDocument& data) override; - -private: - class Private; - QScopedPointer d; + QString eventId() const { return loadFromJson("event_id"_ls); } }; } // namespace Quotient -- cgit v1.2.3 From e17764a1ae81393968dfb747c7b67353c109bc71 Mon Sep 17 00:00:00 2001 From: Kitsune Ral Date: Fri, 19 Jun 2020 15:01:33 +0200 Subject: csapi/: generated using the latest GTAD and matrix-doc For matrix-doc, specifically, it is master (5cb4b086) merged with https://github.com/matrix-org/matrix-doc/pull/2518. --- lib/csapi/redaction.h | 1 - 1 file changed, 1 deletion(-) (limited to 'lib/csapi/redaction.h') diff --git a/lib/csapi/redaction.h b/lib/csapi/redaction.h index c737de41..541e433a 100644 --- a/lib/csapi/redaction.h +++ b/lib/csapi/redaction.h @@ -22,7 +22,6 @@ namespace Quotient { class RedactEventJob : public BaseJob { public: /*! \brief Strips all non-integrity-critical information out of an event. - * * * \param roomId * The room from which to redact the event. -- cgit v1.2.3