OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 {%- set header_guard = "MOJO_GENERATED_BINDINGS_%s_%s_H_"| | 5 {%- set header_guard = "%s_H_"| |
6 format(module_name|upper, module_name|upper) %} | 6 format(module_path|upper|replace("/","_")|replace(".","_")) %} |
7 | 7 |
8 #ifndef {{header_guard}} | 8 #ifndef {{header_guard}} |
9 #define {{header_guard}} | 9 #define {{header_guard}} |
10 | 10 |
11 #include "mojo/public/bindings/array.h" | 11 #include "mojo/public/bindings/array.h" |
12 #include "mojo/public/bindings/interface.h" | 12 #include "mojo/public/bindings/interface.h" |
13 #include "{{include_prefix}}{{module_name|camel_to_underscores}}_internal.h" | 13 #include "{{include_prefix}}{{module_name|camel_to_underscores}}-internal.h" |
14 {%- for import in imports %} | 14 {%- for import in imports %} |
15 #include "{{include_prefix}}{{import.module_name|camel_to_underscores}}.h" | 15 #include "{{include_prefix}}{{import.module_name|camel_to_underscores}}.h" |
16 {%- endfor %} | 16 {%- endfor %} |
17 | 17 |
18 namespace {{namespace}} { | 18 namespace {{namespace}} { |
19 | 19 |
20 {#--- Enums #} | 20 {#--- Enums #} |
21 {% for enum in enums %} | 21 {% for enum in enums %} |
22 {% include "enum_declaration.tmpl" %} | 22 {% include "enum_declaration.tmpl" %} |
23 {%- endfor %} | 23 {%- endfor %} |
(...skipping 14 matching lines...) Expand all Loading... |
38 {%- endfor %} | 38 {%- endfor %} |
39 | 39 |
40 {#--- Interface Stubs -#} | 40 {#--- Interface Stubs -#} |
41 {% for interface in interfaces %} | 41 {% for interface in interfaces %} |
42 {% include "interface_stub_declaration.tmpl" %} | 42 {% include "interface_stub_declaration.tmpl" %} |
43 {%- endfor %} | 43 {%- endfor %} |
44 | 44 |
45 } // namespace {{namespace}} | 45 } // namespace {{namespace}} |
46 | 46 |
47 #endif // {{header_guard}} | 47 #endif // {{header_guard}} |
OLD | NEW |