[Yunq] Add support for empty requests and responses.

This commit is contained in:
Drew Galbraith 2023-11-27 08:03:12 -08:00
parent 6d108f6965
commit cc4b5bd811
11 changed files with 91 additions and 22 deletions

View file

@ -21,7 +21,13 @@ class {{interface.name}}ServerBase {
[[nodiscard]] Thread RunServer();
{% for method in interface.methods %}
{% if method.request == None %}
[[nodiscard]] virtual glcr::ErrorCode Handle{{method.name}}({{method.response}}&) = 0;
{% elif method.response == None %}
[[nodiscard]] virtual glcr::ErrorCode Handle{{method.name}}(const {{method.request}}&) = 0;
{% else %}
[[nodiscard]] virtual glcr::ErrorCode Handle{{method.name}}(const {{method.request}}&, {{method.response}}&) = 0;
{% endif %}
{% endfor %}
private: