OLD | NEW |
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, 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 RUNTIME_BIN_DARTUTILS_H_ | 5 #ifndef RUNTIME_BIN_DARTUTILS_H_ |
6 #define RUNTIME_BIN_DARTUTILS_H_ | 6 #define RUNTIME_BIN_DARTUTILS_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 112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
123 static void WriteFile(const void* buffer, intptr_t num_bytes, void* stream); | 123 static void WriteFile(const void* buffer, intptr_t num_bytes, void* stream); |
124 static void CloseFile(void* stream); | 124 static void CloseFile(void* stream); |
125 static bool EntropySource(uint8_t* buffer, intptr_t length); | 125 static bool EntropySource(uint8_t* buffer, intptr_t length); |
126 static Dart_Handle ReadStringFromFile(const char* filename); | 126 static Dart_Handle ReadStringFromFile(const char* filename); |
127 static Dart_Handle MakeUint8Array(const uint8_t* buffer, intptr_t length); | 127 static Dart_Handle MakeUint8Array(const uint8_t* buffer, intptr_t length); |
128 static Dart_Handle PrepareForScriptLoading(bool is_service_isolate, | 128 static Dart_Handle PrepareForScriptLoading(bool is_service_isolate, |
129 bool trace_loading); | 129 bool trace_loading); |
130 static Dart_Handle SetupServiceLoadPort(); | 130 static Dart_Handle SetupServiceLoadPort(); |
131 static Dart_Handle SetupPackageRoot(const char* package_root, | 131 static Dart_Handle SetupPackageRoot(const char* package_root, |
132 const char* packages_file); | 132 const char* packages_file); |
133 static Dart_Handle SetupIOLibrary(const char* script_uri); | 133 static Dart_Handle SetupIOLibrary(const char* namespc_path, |
| 134 const char* script_uri); |
134 | 135 |
135 static bool PostNull(Dart_Port port_id); | 136 static bool PostNull(Dart_Port port_id); |
136 static bool PostInt32(Dart_Port port_id, int32_t value); | 137 static bool PostInt32(Dart_Port port_id, int32_t value); |
137 static bool PostInt64(Dart_Port port_id, int64_t value); | 138 static bool PostInt64(Dart_Port port_id, int64_t value); |
138 | 139 |
139 static Dart_Handle GetDartType(const char* library_url, | 140 static Dart_Handle GetDartType(const char* library_url, |
140 const char* class_name); | 141 const char* class_name); |
141 // Create a new Dart OSError object with the current OS error. | 142 // Create a new Dart OSError object with the current OS error. |
142 static Dart_Handle NewDartOSError(); | 143 static Dart_Handle NewDartOSError(); |
143 // Create a new Dart OSError object with the provided OS error. | 144 // Create a new Dart OSError object with the provided OS error. |
(...skipping 493 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
637 bool is_typed_data_; | 638 bool is_typed_data_; |
638 | 639 |
639 DISALLOW_ALLOCATION(); | 640 DISALLOW_ALLOCATION(); |
640 DISALLOW_COPY_AND_ASSIGN(ScopedMemBuffer); | 641 DISALLOW_COPY_AND_ASSIGN(ScopedMemBuffer); |
641 }; | 642 }; |
642 | 643 |
643 } // namespace bin | 644 } // namespace bin |
644 } // namespace dart | 645 } // namespace dart |
645 | 646 |
646 #endif // RUNTIME_BIN_DARTUTILS_H_ | 647 #endif // RUNTIME_BIN_DARTUTILS_H_ |
OLD | NEW |