Chromium Code Reviews| 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 INCLUDE_DART_API_H_ | 5 #ifndef INCLUDE_DART_API_H_ |
| 6 #define INCLUDE_DART_API_H_ | 6 #define INCLUDE_DART_API_H_ |
| 7 | 7 |
| 8 /** \mainpage Dart Embedding API Reference | 8 /** \mainpage Dart Embedding API Reference |
| 9 * | 9 * |
| 10 * Dart is a class-based programming language for creating structured | 10 * Dart is a class-based programming language for creating structured |
| (...skipping 2519 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 2530 * the current isolate.. | 2530 * the current isolate.. |
| 2531 * | 2531 * |
| 2532 * TODO(turnidge): Document. | 2532 * TODO(turnidge): Document. |
| 2533 */ | 2533 */ |
| 2534 DART_EXPORT Dart_Handle Dart_CompileAll(); | 2534 DART_EXPORT Dart_Handle Dart_CompileAll(); |
| 2535 | 2535 |
| 2536 /** | 2536 /** |
| 2537 * Is this object a Library? | 2537 * Is this object a Library? |
| 2538 */ | 2538 */ |
| 2539 DART_EXPORT bool Dart_IsLibrary(Dart_Handle object); | 2539 DART_EXPORT bool Dart_IsLibrary(Dart_Handle object); |
| 2540 | 2540 |
|
Ivan Posva
2012/08/27 23:55:00
?
Mads Ager (google)
2012/08/28 05:58:31
Done.
| |
| 2541 | |
| 2541 /** | 2542 /** |
| 2542 * Lookup a class or interface by name from a Library. | 2543 * Lookup a class or interface by name from a Library. |
| 2543 * | 2544 * |
| 2544 * \param library The library containing the class or interface. | 2545 * \param library The library containing the class or interface. |
| 2545 * \param class_name The name of the class or interface. | 2546 * \param class_name The name of the class or interface. |
| 2546 * | 2547 * |
| 2547 * \return If no error occurs, the class or interface is | 2548 * \return If no error occurs, the class or interface is |
| 2548 * returned. Otherwise an error handle is returned. | 2549 * returned. Otherwise an error handle is returned. |
| 2549 */ | 2550 */ |
| 2550 DART_EXPORT Dart_Handle Dart_GetClass(Dart_Handle library, | 2551 DART_EXPORT Dart_Handle Dart_GetClass(Dart_Handle library, |
| (...skipping 22 matching lines...) Expand all Loading... | |
| 2573 | 2574 |
| 2574 DART_EXPORT Dart_Handle Dart_LookupLibrary(Dart_Handle url); | 2575 DART_EXPORT Dart_Handle Dart_LookupLibrary(Dart_Handle url); |
| 2575 // TODO(turnidge): Consider returning Dart_Null() when the library is | 2576 // TODO(turnidge): Consider returning Dart_Null() when the library is |
| 2576 // not found to distinguish that from a true error case. | 2577 // not found to distinguish that from a true error case. |
| 2577 | 2578 |
| 2578 DART_EXPORT Dart_Handle Dart_LoadLibrary(Dart_Handle url, | 2579 DART_EXPORT Dart_Handle Dart_LoadLibrary(Dart_Handle url, |
| 2579 Dart_Handle source); | 2580 Dart_Handle source); |
| 2580 | 2581 |
| 2581 | 2582 |
| 2582 DART_EXPORT Dart_Handle Dart_LibraryImportLibrary(Dart_Handle library, | 2583 DART_EXPORT Dart_Handle Dart_LibraryImportLibrary(Dart_Handle library, |
| 2583 Dart_Handle import); | 2584 Dart_Handle import, |
| 2585 Dart_Handle prefix); | |
| 2584 | 2586 |
| 2585 /** | 2587 /** |
| 2586 * Loads a source string into a library. | 2588 * Loads a source string into a library. |
| 2587 * | 2589 * |
| 2588 * \param library A library | 2590 * \param library A library |
| 2589 * \param url A url identifying the origin of the source | 2591 * \param url A url identifying the origin of the source |
| 2590 * \param source A string of Dart source | 2592 * \param source A string of Dart source |
| 2591 * | 2593 * |
| 2592 * \return A valid handle if no error occurs during the operation. | 2594 * \return A valid handle if no error occurs during the operation. |
| 2593 */ | 2595 */ |
| (...skipping 25 matching lines...) Expand all Loading... | |
| 2619 | 2621 |
| 2620 typedef void (*Dart_FileWriterFunction)(const char* buffer, int64_t num_bytes); | 2622 typedef void (*Dart_FileWriterFunction)(const char* buffer, int64_t num_bytes); |
| 2621 | 2623 |
| 2622 // Support for generating symbol maps for use by the Linux perf tool. | 2624 // Support for generating symbol maps for use by the Linux perf tool. |
| 2623 DART_EXPORT void Dart_InitPerfEventsSupport(Dart_FileWriterFunction function); | 2625 DART_EXPORT void Dart_InitPerfEventsSupport(Dart_FileWriterFunction function); |
| 2624 | 2626 |
| 2625 // Support for generating flow graph compiler debugging output into a file. | 2627 // Support for generating flow graph compiler debugging output into a file. |
| 2626 DART_EXPORT void Dart_InitFlowGraphPrinting(Dart_FileWriterFunction function); | 2628 DART_EXPORT void Dart_InitFlowGraphPrinting(Dart_FileWriterFunction function); |
| 2627 | 2629 |
| 2628 #endif // INCLUDE_DART_API_H_ | 2630 #endif // INCLUDE_DART_API_H_ |
| OLD | NEW |