summaryrefslogtreecommitdiff
path: root/.mailmap
diff options
context:
space:
mode:
authortaylor.woll <tawoll@ntdev.microsoft.com>2017-03-28 02:06:58 -0700
committerAnna Henningsen <anna@addaleax.net>2017-04-11 01:09:46 +0200
commit9decfb15215978b73094ffb7a4bdf2a0da010258 (patch)
treec49d73c4cd519aba60e7a86b7ea5779ac73d675f /.mailmap
parentca786c3734f6e23e34cd60f13e6bdaab033c5739 (diff)
downloadandroid-node-v8-9decfb15215978b73094ffb7a4bdf2a0da010258.tar.gz
android-node-v8-9decfb15215978b73094ffb7a4bdf2a0da010258.tar.bz2
android-node-v8-9decfb15215978b73094ffb7a4bdf2a0da010258.zip
n-api: implement async helper methods
Based on the async methods we had in abi-stable-node before the napi feature landed in node/master. Changed this set of APIs to handle error cases and removed a lot of the extra methods we had for setting all the pieces of napi_work opting instead to pass all of those as arguments to napi_create_async_work as none of those parameters are optional except for the complete callback, anyway. Renamed the napi_work struct to napi_async_work and replace the struct itself with a class which can better encapsulate the object lifetime and uv_work_t that we're trying to wrap anyway. Added a napi_async_callback type for the async helper callbacks instead of taking raw function pointers and make this callback take a napi_env parameter as well as the void* data it was already taking. Call the complete handler for the async work item with a napi_status code translated from the uvlib error code. The execute callback is required for napi_create_async_work, though complete callback is still optional. Also added some async unit tests for addons-napi based on the addons/async_hello_world test. PR-URL: https://github.com/nodejs/node/pull/12250 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Timothy Gu <timothygu99@gmail.com> Reviewed-By: Hitesh Kanwathirtha <hiteshk@microsoft.com>
Diffstat (limited to '.mailmap')
0 files changed, 0 insertions, 0 deletions