| OLD | NEW |
| 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef BIN_LOADER_H_ | 5 #ifndef BIN_LOADER_H_ |
| 6 #define BIN_LOADER_H_ | 6 #define BIN_LOADER_H_ |
| 7 | 7 |
| 8 #include "bin/isolate_data.h" | 8 #include "bin/isolate_data.h" |
| 9 #include "include/dart_api.h" | 9 #include "include/dart_api.h" |
| 10 #include "include/dart_native_api.h" | 10 #include "include/dart_native_api.h" |
| (...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 77 intptr_t results_length() { | 77 intptr_t results_length() { |
| 78 return *static_cast<volatile intptr_t*>(&results_length_); | 78 return *static_cast<volatile intptr_t*>(&results_length_); |
| 79 } | 79 } |
| 80 | 80 |
| 81 // Send the loader init request to the service isolate. | 81 // Send the loader init request to the service isolate. |
| 82 void Init(const char* package_root, | 82 void Init(const char* package_root, |
| 83 const char* packages_file, | 83 const char* packages_file, |
| 84 const char* working_directory, | 84 const char* working_directory, |
| 85 const char* root_script_uri); | 85 const char* root_script_uri); |
| 86 | 86 |
| 87 // Send a request for a dart-ext: import to the service isolate. |
| 88 void SendImportExtensionRequest(Dart_Handle url, |
| 89 Dart_Handle library_url); |
| 90 |
| 87 // Send a request from the tag handler to the service isolate. | 91 // Send a request from the tag handler to the service isolate. |
| 88 void SendRequest(Dart_LibraryTag tag, | 92 void SendRequest(Dart_LibraryTag tag, |
| 89 Dart_Handle url, | 93 Dart_Handle url, |
| 90 Dart_Handle library_url); | 94 Dart_Handle library_url); |
| 91 | 95 |
| 92 /// Queue |message| and notify the loader that a message is available. | 96 /// Queue |message| and notify the loader that a message is available. |
| 93 void QueueMessage(Dart_CObject* message); | 97 void QueueMessage(Dart_CObject* message); |
| 94 | 98 |
| 95 /// Blocks the caller until the loader is finished. | 99 /// Blocks the caller until the loader is finished. |
| 96 void BlockUntilComplete(ProcessResult process_result); | 100 void BlockUntilComplete(ProcessResult process_result); |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 135 | 139 |
| 136 // This is the global callback for the native message handlers. | 140 // This is the global callback for the native message handlers. |
| 137 static void NativeMessageHandler(Dart_Port dest_port_id, | 141 static void NativeMessageHandler(Dart_Port dest_port_id, |
| 138 Dart_CObject* message); | 142 Dart_CObject* message); |
| 139 }; | 143 }; |
| 140 | 144 |
| 141 } // namespace bin | 145 } // namespace bin |
| 142 } // namespace dart | 146 } // namespace dart |
| 143 | 147 |
| 144 #endif // BIN_LOADER_H_ | 148 #endif // BIN_LOADER_H_ |
| OLD | NEW |