Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(157)

Side by Side Diff: mojo/public/tools/bindings/generators/cpp_templates/module.h.tmpl

Issue 1660403003: Mojo C++ bindings: Rename InterfaceInfoPtr -> InterfaceHandle (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: using {{InterfaceName}}Handle = InterfaceHandle<{{InterfaceName}}> Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 {#- TODO(vardhan): This template produces crazy amounts of whitespace. Clean 1 {#- TODO(vardhan): This template produces crazy amounts of whitespace. Clean
2 this stuff up (it involves digging through all the templates included here. -#} 2 this stuff up (it involves digging through all the templates included here. -#}
3 // Copyright 2013 The Chromium Authors. All rights reserved. 3 // Copyright 2013 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 {%- import "struct_macros.tmpl" as struct_macros %} 7 {%- import "struct_macros.tmpl" as struct_macros %}
8 {% import "interface_macros.tmpl" as interface_macros -%} 8 {% import "interface_macros.tmpl" as interface_macros -%}
9 {%- set header_guard = "%s_H_"| 9 {%- set header_guard = "%s_H_"|
10 format(module.path|upper|replace("/","_")|replace(".","_")) %} 10 format(module.path|upper|replace("/","_")|replace(".","_")) %}
(...skipping 25 matching lines...) Expand all
36 {#------------------------ #} 36 {#------------------------ #}
37 37
38 {%- for namespace in namespaces_as_array %} 38 {%- for namespace in namespaces_as_array %}
39 namespace {{namespace}} { 39 namespace {{namespace}} {
40 {%- endfor %} 40 {%- endfor %}
41 41
42 {#--- Interface Forward Declarations -#} 42 {#--- Interface Forward Declarations -#}
43 {% for interface in interfaces %} 43 {% for interface in interfaces %}
44 class {{interface.name}}; 44 class {{interface.name}};
45 using {{interface.name}}Ptr = mojo::InterfacePtr<{{interface.name}}>; 45 using {{interface.name}}Ptr = mojo::InterfacePtr<{{interface.name}}>;
46 using {{interface.name}}Handle = mojo::InterfaceHandle<{{interface.name}}>;
46 {% endfor %} 47 {% endfor %}
47 48
48 {#--- Struct Forward Declarations -#} 49 {#--- Struct Forward Declarations -#}
49 {% for struct in structs %} 50 {% for struct in structs %}
50 {{ struct_macros.structptr_forward_decl(struct) }} 51 {{ struct_macros.structptr_forward_decl(struct) }}
51 {% endfor %} 52 {% endfor %}
52 53
53 {#--- Union Forward Declarations -#} 54 {#--- Union Forward Declarations -#}
54 {% for union in unions %} 55 {% for union in unions %}
55 class {{union.name}}; 56 class {{union.name}};
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after
175 {#--- Request and response parameter structs for Interface methods -#} 176 {#--- Request and response parameter structs for Interface methods -#}
176 {% for interface in interfaces -%} 177 {% for interface in interfaces -%}
177 {{interface_macros.declare_param_structs_for_interface(interface)}} 178 {{interface_macros.declare_param_structs_for_interface(interface)}}
178 {%- endfor %} 179 {%- endfor %}
179 180
180 {%- for namespace in namespaces_as_array|reverse %} 181 {%- for namespace in namespaces_as_array|reverse %}
181 } // namespace {{namespace}} 182 } // namespace {{namespace}}
182 {%- endfor %} 183 {%- endfor %}
183 184
184 #endif // {{header_guard}} 185 #endif // {{header_guard}}
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698