| OLD | NEW |
| 1 // This file is generated | 1 // This file is generated |
| 2 | 2 |
| 3 // Copyright (c) 2016 The Chromium Authors. All rights reserved. | 3 // Copyright (c) 2016 The Chromium Authors. All rights reserved. |
| 4 // Use of this source code is governed by a BSD-style license that can be | 4 // Use of this source code is governed by a BSD-style license that can be |
| 5 // found in the LICENSE file. | 5 // found in the LICENSE file. |
| 6 | 6 |
| 7 #ifndef {{"_".join(config.protocol.namespace)}}_{{domain.domain}}_h | 7 #ifndef {{"_".join(config.protocol.namespace)}}_{{domain.domain}}_h |
| 8 #define {{"_".join(config.protocol.namespace)}}_{{domain.domain}}_h | 8 #define {{"_".join(config.protocol.namespace)}}_{{domain.domain}}_h |
| 9 | 9 |
| 10 {% if config.protocol.export_header %} | 10 {% if config.protocol.export_header %} |
| (...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 197 {%- for parameter in command.returns -%} | 197 {%- for parameter in command.returns -%} |
| 198 {%- if "optional" in parameter -%} | 198 {%- if "optional" in parameter -%} |
| 199 Maybe<{{resolve_type(parameter).raw_type}}> {{parameter.name}} | 199 Maybe<{{resolve_type(parameter).raw_type}}> {{parameter.name}} |
| 200 {%- else -%} | 200 {%- else -%} |
| 201 {{resolve_type(parameter).pass_type}} {{parameter.name}} | 201 {{resolve_type(parameter).pass_type}} {{parameter.name}} |
| 202 {%- endif -%} | 202 {%- endif -%} |
| 203 {%- if not loop.last -%}, {% endif -%} | 203 {%- if not loop.last -%}, {% endif -%} |
| 204 {%- endfor -%} | 204 {%- endfor -%} |
| 205 ) = 0; | 205 ) = 0; |
| 206 virtual void sendFailure(const DispatchResponse&) = 0; | 206 virtual void sendFailure(const DispatchResponse&) = 0; |
| 207 virtual ~{{command.name | to_title_case}}Callback() { } |
| 207 }; | 208 }; |
| 208 {% endif %} | 209 {% endif %} |
| 209 {%- if not("async" in command) %} | 210 {%- if not("async" in command) %} |
| 210 virtual DispatchResponse {{command.name}}( | 211 virtual DispatchResponse {{command.name}}( |
| 211 {%- else %} | 212 {%- else %} |
| 212 virtual void {{command.name}}( | 213 virtual void {{command.name}}( |
| 213 {%- endif %} | 214 {%- endif %} |
| 214 {%- for parameter in command.parameters -%} | 215 {%- for parameter in command.parameters -%} |
| 215 {%- if not loop.first -%}, {% endif -%} | 216 {%- if not loop.first -%}, {% endif -%} |
| 216 {%- if "optional" in parameter -%} | 217 {%- if "optional" in parameter -%} |
| (...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 287 static const char commandPrefix[]; | 288 static const char commandPrefix[]; |
| 288 static const char version[]; | 289 static const char version[]; |
| 289 }; | 290 }; |
| 290 | 291 |
| 291 } // namespace {{domain.domain}} | 292 } // namespace {{domain.domain}} |
| 292 {% for namespace in config.protocol.namespace %} | 293 {% for namespace in config.protocol.namespace %} |
| 293 } // namespace {{namespace}} | 294 } // namespace {{namespace}} |
| 294 {% endfor %} | 295 {% endfor %} |
| 295 | 296 |
| 296 #endif // !defined({{"_".join(config.protocol.namespace)}}_{{domain.domain}}_h) | 297 #endif // !defined({{"_".join(config.protocol.namespace)}}_{{domain.domain}}_h) |
| OLD | NEW |