napi_open_escapable_handle_scope
NAPI_EXTERN napi_status
napi_open_escapable_handle_scope(napi_env env,
napi_handle_scope* result); -
[in] env:调用 API 的环境。¥
[in] env: The environment that the API is invoked under. -
[out] result:napi_value代表新范围。¥
[out] result:napi_valuerepresenting the new scope.
如果 API 成功,则返回 napi_ok。
¥Returns napi_ok if the API succeeded.
此 API 会打开一个新范围,从中可以将一个对象提升到外部范围。
¥This API opens a new scope from which one object can be promoted to the outer scope.