diff options
author | Kitsune Ral <Kitsune-Ral@users.sf.net> | 2017-10-02 14:31:51 +0900 |
---|---|---|
committer | Kitsune Ral <Kitsune-Ral@users.sf.net> | 2017-10-02 14:31:51 +0900 |
commit | ab33516eb9aed5db5decb572cb30a83971f4c51e (patch) | |
tree | b126c3b8338eefe8530a285703f350ffe0924a7a /jobs/{{base}}.h.mustache | |
parent | b2c9daabc2e8b89e1108211d8c9badf1bac66640 (diff) | |
download | libquotient-ab33516eb9aed5db5decb572cb30a83971f4c51e.tar.gz libquotient-ab33516eb9aed5db5decb572cb30a83971f4c51e.zip |
Drop ConnectionData parameter from {{template}} files too; less blanks
Diffstat (limited to 'jobs/{{base}}.h.mustache')
-rw-r--r-- | jobs/{{base}}.h.mustache | 46 |
1 files changed, 12 insertions, 34 deletions
diff --git a/jobs/{{base}}.h.mustache b/jobs/{{base}}.h.mustache index 6fb9caef..e19cf03d 100644 --- a/jobs/{{base}}.h.mustache +++ b/jobs/{{base}}.h.mustache @@ -2,22 +2,14 @@ #pragma once -{{#operations}} -#include "../basejob.h" -{{/operations}} - +{{#operations}}#include "../basejob.h"{{/operations}} {{#imports}} #include {{.}} {{/imports}} - -{{#models}} -#include <QtCore/QJsonValue> {{! FIXME: This should probably go inside imports }} -{{/models}} - +{{#models}}#include <QtCore/QJsonValue>{{/models}}{{! FIXME: This should probably go inside imports }} namespace QMatrixClient { -{{#models}} - // Data structures +{{#models}} // Data structures {{#model}} struct {{classname}} { @@ -25,41 +17,27 @@ namespace QMatrixClient {{datatype}} {{name}}; {{/vars}} operator QJsonValue() const { return {}; } - }; - {{/model}} + };{{/model}} {{/models}} -{{#operations}} - // Operations +{{#operations}} // Operations {{#operation}} class {{#@cap}}{{operationId}}{{/@cap}}Job : public BaseJob { public: - {{#@cap}}{{operationId}}{{/@cap}}Job(const ConnectionData* connection - {{#allParams}} - , {{!}} - {{#avoidCopy?}}const {{dataType}}&{{/avoidCopy?}} - {{^avoidCopy?}}{{dataType}}{{/avoidCopy?}} {{paramName}} - {{/allParams}}); - {{#returns?}} + {{#@cap}}{{operationId}}{{/@cap}}Job({{#allParams}}{{#avoidCopy?}}const {{dataType}}&{{/avoidCopy?}}{{^avoidCopy?}}{{dataType}}{{/avoidCopy?}} {{paramName}}{{#hasMore}}, {{/hasMore}}{{/allParams}}); + {{#returns?}} virtual {{className}}Job(); - {{#returns}} - {{type}} {{name}}() const; - {{/returns}} + {{#returns}}{{type}} {{name}}() const;{{/returns}} protected: - {{#returnFile?}} - Status parseReply(QByteArray data) override; - {{/returnFile?}} - {{^returnFile}} - Status parseJson(const JsonDocument& data) override; - {{/returnFile}} + {{#returnFile?}}Status parseReply(QByteArray data) override;{{/returnFile?}} + {{^returnFile}}Status parseJson(const JsonDocument& data) override;{{/returnFile}} private: class Private; Private* d; - {{/returns?}} - }; - {{/operation}} + {{/returns?}} + };{{/operation}} {{/operations}} } // namespace QMatrixClient |