OLD | NEW |
---|---|
1 /* | 1 /* |
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 | 6 |
7 #ifndef INCLUDE_DART_API_H_ | 7 #ifndef INCLUDE_DART_API_H_ |
8 #define INCLUDE_DART_API_H_ | 8 #define INCLUDE_DART_API_H_ |
9 | 9 |
10 /** \mainpage Dart Embedding API Reference | 10 /** \mainpage Dart Embedding API Reference |
(...skipping 1735 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1746 * \return If the constructor is called and completes successfully, | 1746 * \return If the constructor is called and completes successfully, |
1747 * then the new object. If an error occurs during execution, then an | 1747 * then the new object. If an error occurs during execution, then an |
1748 * error handle is returned. | 1748 * error handle is returned. |
1749 */ | 1749 */ |
1750 DART_EXPORT Dart_Handle Dart_New(Dart_Handle clazz, | 1750 DART_EXPORT Dart_Handle Dart_New(Dart_Handle clazz, |
1751 Dart_Handle constructor_name, | 1751 Dart_Handle constructor_name, |
1752 int number_of_arguments, | 1752 int number_of_arguments, |
1753 Dart_Handle* arguments); | 1753 Dart_Handle* arguments); |
1754 | 1754 |
1755 /** | 1755 /** |
1756 * Allocate a new object without invoking a constructor. | |
1757 * | |
1758 * \param clazz A class or an interface. | |
siva
2013/06/18 00:52:14
Note:
Since we plan on moving all the invoke/new e
vsm
2013/06/19 14:55:12
Updated to accept Type as well.
On 2013/06/18 00:
| |
1759 * | |
1760 * \return The new object. If an error occurs during execution, then an | |
1761 * error handle is returned. | |
1762 */ | |
1763 DART_EXPORT Dart_Handle Dart_Allocate(Dart_Handle clazz); | |
1764 | |
1765 /** | |
1756 * Invokes a method or function. | 1766 * Invokes a method or function. |
1757 * | 1767 * |
1758 * The 'target' parameter may be an object, class, or library. If | 1768 * The 'target' parameter may be an object, class, or library. If |
1759 * 'target' is an object, then this function will invoke an instance | 1769 * 'target' is an object, then this function will invoke an instance |
1760 * method. If 'target' is a class, then this function will invoke a | 1770 * method. If 'target' is a class, then this function will invoke a |
1761 * static method. If 'target' is a library, then this function will | 1771 * static method. If 'target' is a library, then this function will |
1762 * invoke a top-level function from that library. | 1772 * invoke a top-level function from that library. |
1763 * | 1773 * |
1764 * This function ignores visibility (leading underscores in names). | 1774 * This function ignores visibility (leading underscores in names). |
1765 * | 1775 * |
(...skipping 390 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2156 * | 2166 * |
2157 * \param object An object. | 2167 * \param object An object. |
2158 * \param peer A value to store in the peer field. | 2168 * \param peer A value to store in the peer field. |
2159 * | 2169 * |
2160 * \return Returns an error if 'object' is a subtype of Null, num, or | 2170 * \return Returns an error if 'object' is a subtype of Null, num, or |
2161 * bool. | 2171 * bool. |
2162 */ | 2172 */ |
2163 DART_EXPORT Dart_Handle Dart_SetPeer(Dart_Handle object, void* peer); | 2173 DART_EXPORT Dart_Handle Dart_SetPeer(Dart_Handle object, void* peer); |
2164 | 2174 |
2165 #endif /* INCLUDE_DART_API_H_ */ /* NOLINT */ | 2175 #endif /* INCLUDE_DART_API_H_ */ /* NOLINT */ |
OLD | NEW |