diff options
Diffstat (limited to 'mojo/public/tools/bindings/generators/cpp_templates/wrapper_class_definition.tmpl')
-rw-r--r-- | mojo/public/tools/bindings/generators/cpp_templates/wrapper_class_definition.tmpl | 39 |
1 files changed, 0 insertions, 39 deletions
diff --git a/mojo/public/tools/bindings/generators/cpp_templates/wrapper_class_definition.tmpl b/mojo/public/tools/bindings/generators/cpp_templates/wrapper_class_definition.tmpl deleted file mode 100644 index ab8c22d..0000000 --- a/mojo/public/tools/bindings/generators/cpp_templates/wrapper_class_definition.tmpl +++ /dev/null @@ -1,39 +0,0 @@ -{% for constructor in struct|struct_constructors %} -{{struct.name}}::{{struct.name}}( -{%- for field in constructor.params %} -{%- set type = field.kind|cpp_wrapper_param_type %} -{%- set name = field.name %} - {{type}} {{name}}_in -{%- if not loop.last -%},{%- endif %} -{%- endfor %}) -{%- for field, is_parameter in constructor.fields %} -{%- set name = field.name %} - {% if loop.first %}:{% else %} {% endif %} {{name}}( -{%- if is_parameter -%} -std::move({{name}}_in) -{%- else -%} -{{ field|default_value }} -{%- endif -%} -){% if not loop.last %},{% endif %} -{%- endfor %} {} -{% endfor %} -{{struct.name}}::~{{struct.name}}() = default; - -{%- if struct|is_hashable %} -size_t {{struct.name}}::Hash(size_t seed) const { -{%- for field in struct.fields %} -{%- if for_blink %} - seed = mojo::internal::WTFHash(seed, this->{{field.name}}); -{%- else %} - seed = mojo::internal::Hash(seed, this->{{field.name}}); -{%- endif %} -{%- endfor %} - return seed; -} -{%- endif %} - -bool {{struct.name}}::Validate( - const void* data, - mojo::internal::ValidationContext* validation_context) { - return Data_::Validate(data, validation_context); -} |