aboutsummaryrefslogtreecommitdiff
path: root/lib/csapi/gtad.yaml
diff options
context:
space:
mode:
authorBlack Hat <bhat@encom.eu.org>2019-09-26 22:22:36 -0700
committerBlack Hat <bhat@encom.eu.org>2019-09-26 22:22:36 -0700
commit363cf452bcdbaf6ff1cf94a83ca66cbb31122346 (patch)
treec64c8fda885e4e1785130e8ee3e7c47fd18cbf67 /lib/csapi/gtad.yaml
parent412e2cf19449e73aa7da729e9c5de6502687aade (diff)
parent944653463fe4134c82d85e2d01e2bc0fa43fd727 (diff)
downloadlibquotient-363cf452bcdbaf6ff1cf94a83ca66cbb31122346.tar.gz
libquotient-363cf452bcdbaf6ff1cf94a83ca66cbb31122346.zip
Merge branch 'master' of https://github.com/quotient-im/libQuotient into
bhat-libqtolm-update
Diffstat (limited to 'lib/csapi/gtad.yaml')
-rw-r--r--lib/csapi/gtad.yaml12
1 files changed, 10 insertions, 2 deletions
diff --git a/lib/csapi/gtad.yaml b/lib/csapi/gtad.yaml
index a44f803a..301ee0b6 100644
--- a/lib/csapi/gtad.yaml
+++ b/lib/csapi/gtad.yaml
@@ -118,24 +118,32 @@ mustache:
# _rightQuote: '"'
# _joinChar: ',' # The character used by {{_join}} - not working yet
_comment: '//'
+ copyrightName: Kitsune Ral
+ copyrightEmail: <kitsune-ral@users.sf.net>
+
partials:
_typeRenderer: "{{#scope}}{{scopeCamelCase}}Job::{{/scope}}{{>name}}"
omittedValue: '{}' # default value to initialize omitted parameters with
initializer: '{{defaultValue}}'
cjoin: '{{#hasMore}}, {{/hasMore}}'
+
openOmittable: "{{^required?}}{{#useOmittable}}{{^defaultValue}}Omittable<{{/defaultValue}}{{/useOmittable}}{{/required?}}"
closeOmittable: "{{^required?}}{{#useOmittable}}{{^defaultValue}}>{{/defaultValue}}{{/useOmittable}}{{/required?}}"
+
maybeOmittableType: "{{>openOmittable}}{{dataType.name}}{{>closeOmittable}}"
qualifiedMaybeOmittableType: "{{>openOmittable}}{{dataType.qualifiedName}}{{>closeOmittable}}"
+
maybeCrefType: "{{#avoidCopy}}const {{/avoidCopy}}{{>maybeOmittableType}}{{#avoidCopy}}&{{/avoidCopy}}{{#moveOnly}}&&{{/moveOnly}}"
qualifiedMaybeCrefType:
"{{#avoidCopy}}const {{/avoidCopy}}{{>qualifiedMaybeOmittableType}}{{#avoidCopy}}&{{/avoidCopy}}{{#moveOnly}}&&{{/moveOnly}}"
+
+ maybeCrefJsonObject: "{{^propertyMap}}const QJsonObject&{{/propertyMap}}{{#propertyMap}}QJsonObject{{/propertyMap}}"
+ takeOrValue: "{{#propertyMap}}take{{/propertyMap}}{{^propertyMap}}value{{/propertyMap}}"
+
initializeDefaultValue: "{{#defaultValue}}{{>initializer}}{{/defaultValue}}{{^defaultValue}}{{>omittedValue}}{{/defaultValue}}"
joinedParamDecl: '{{>maybeCrefType}} {{paramName}}{{^required?}} = {{>initializeDefaultValue}}{{/required?}}{{>cjoin}}'
joinedParamDef: '{{>maybeCrefType}} {{paramName}}{{>cjoin}}'
passQueryParams: '{{#queryParams}}{{paramName}}{{>cjoin}}{{/queryParams}}'
- copyrightName: Kitsune Ral
- copyrightEmail: <kitsune-ral@users.sf.net>
templates:
- "{{base}}.h.mustache"