| OLD | NEW |
| 1 #!/usr/bin/python | 1 #!/usr/bin/python |
| 2 # Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 2 # Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 3 # for details. All rights reserved. Use of this source code is governed by a | 3 # for details. All rights reserved. Use of this source code is governed by a |
| 4 # BSD-style license that can be found in the LICENSE file. | 4 # BSD-style license that can be found in the LICENSE file. |
| 5 | 5 |
| 6 """This module provides shared functionality for the system to generate | 6 """This module provides shared functionality for the system to generate |
| 7 Dart:html APIs from the IDL database.""" | 7 Dart:html APIs from the IDL database.""" |
| 8 | 8 |
| 9 import emitter | 9 import emitter |
| 10 import logging | 10 import logging |
| (...skipping 879 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 890 '\n', | 890 '\n', |
| 891 CONVERT=conversion.function_name, | 891 CONVERT=conversion.function_name, |
| 892 HTML_NAME=html_name, | 892 HTML_NAME=html_name, |
| 893 NAME=attr.id, | 893 NAME=attr.id, |
| 894 INPUT_TYPE=conversion.input_type, | 894 INPUT_TYPE=conversion.input_type, |
| 895 NATIVE_TYPE=conversion.output_type) | 895 NATIVE_TYPE=conversion.output_type) |
| 896 | 896 |
| 897 def AmendIndexer(self, element_type): | 897 def AmendIndexer(self, element_type): |
| 898 pass | 898 pass |
| 899 | 899 |
| 900 def RootClassName(self): |
| 901 return 'Interceptor' |
| 902 |
| 900 def EmitOperation(self, info, html_name): | 903 def EmitOperation(self, info, html_name): |
| 901 """ | 904 """ |
| 902 Arguments: | 905 Arguments: |
| 903 info: An OperationInfo object. | 906 info: An OperationInfo object. |
| 904 """ | 907 """ |
| 905 if self._HasCustomImplementation(info.name): | 908 if self._HasCustomImplementation(info.name): |
| 906 return | 909 return |
| 907 | 910 |
| 908 if IsPureInterface(self._interface.id): | 911 if IsPureInterface(self._interface.id): |
| 909 self._AddInterfaceOperation(info, html_name) | 912 self._AddInterfaceOperation(info, html_name) |
| (...skipping 278 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1188 for library_name in libraries: | 1191 for library_name in libraries: |
| 1189 self._libraries[library_name] = DartLibrary( | 1192 self._libraries[library_name] = DartLibrary( |
| 1190 library_name, template_loader, library_type, output_dir) | 1193 library_name, template_loader, library_type, output_dir) |
| 1191 | 1194 |
| 1192 def AddFile(self, basename, library_name, path): | 1195 def AddFile(self, basename, library_name, path): |
| 1193 self._libraries[library_name].AddFile(path) | 1196 self._libraries[library_name].AddFile(path) |
| 1194 | 1197 |
| 1195 def Emit(self, emitter, auxiliary_dir): | 1198 def Emit(self, emitter, auxiliary_dir): |
| 1196 for lib in self._libraries.values(): | 1199 for lib in self._libraries.values(): |
| 1197 lib.Emit(emitter, auxiliary_dir) | 1200 lib.Emit(emitter, auxiliary_dir) |
| OLD | NEW |