Linux unitednationsplay.com 3.10.0-1160.45.1.el7.x86_64 #1 SMP Wed Oct 13 17:20:51 UTC 2021 x86_64
nginx/1.20.1
Server IP : 188.130.139.92 & Your IP : 3.141.199.214
Domains :
Cant Read [ /etc/named.conf ]
User : web
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
home /
www /
unp-musonza /
node_modules /
nan /
doc /
Delete
Unzip
Name
Size
Permission
Date
Action
asyncworker.md
5.23
KB
-rw-r--r--
2018-02-22 17:07
buffers.md
2.07
KB
-rw-r--r--
2017-04-05 22:07
callback.md
2.57
KB
-rw-r--r--
2018-02-22 17:07
converters.md
1.9
KB
-rw-r--r--
2017-04-05 22:07
errors.md
7.23
KB
-rw-r--r--
2017-11-06 23:36
json.md
1.9
KB
-rw-r--r--
2017-11-06 23:36
maybe_types.md
21.87
KB
-rw-r--r--
2018-03-16 15:57
methods.md
26.6
KB
-rw-r--r--
2018-08-25 12:11
new.md
4.75
KB
-rw-r--r--
2017-11-06 23:36
node_misc.md
5.57
KB
-rw-r--r--
2018-08-25 12:11
object_wrappers.md
8.03
KB
-rw-r--r--
2018-08-25 12:11
persistent.md
10.63
KB
-rw-r--r--
2018-09-29 08:02
scopes.md
2.31
KB
-rw-r--r--
2017-11-06 23:36
script.md
1.25
KB
-rw-r--r--
2017-11-06 23:36
string_bytes.md
1.86
KB
-rw-r--r--
2017-04-05 22:07
v8_internals.md
7.23
KB
-rw-r--r--
2017-11-15 11:00
v8_misc.md
2.85
KB
-rw-r--r--
2017-11-06 23:36
Save
Rename
## Scopes A _local handle_ is a pointer to an object. All V8 objects are accessed using handles, they are necessary because of the way the V8 garbage collector works. A handle scope can be thought of as a container for any number of handles. When you've finished with your handles, instead of deleting each one individually you can simply delete their scope. The creation of `HandleScope` objects is different across the supported versions of V8. Therefore, NAN provides its own implementations that can be used safely across these. - <a href="#api_nan_handle_scope"><b><code>Nan::HandleScope</code></b></a> - <a href="#api_nan_escapable_handle_scope"><b><code>Nan::EscapableHandleScope</code></b></a> Also see the V8 Embedders Guide section on [Handles and Garbage Collection](https://github.com/v8/v8/wiki/Embedder%27s%20Guide#handles-and-garbage-collection). <a name="api_nan_handle_scope"></a> ### Nan::HandleScope A simple wrapper around [`v8::HandleScope`](https://v8docs.nodesource.com/io.js-3.3/d3/d95/classv8_1_1_handle_scope.html). Definition: ```c++ class Nan::HandleScope { public: Nan::HandleScope(); static int NumberOfHandles(); }; ``` Allocate a new `Nan::HandleScope` whenever you are creating new V8 JavaScript objects. Note that an implicit `HandleScope` is created for you on JavaScript-accessible methods so you do not need to insert one yourself. Example: ```c++ // new object is created, it needs a new scope: void Pointless() { Nan::HandleScope scope; v8::Local<v8::Object> obj = Nan::New<v8::Object>(); } // JavaScript-accessible method already has a HandleScope NAN_METHOD(Pointless2) { v8::Local<v8::Object> obj = Nan::New<v8::Object>(); } ``` <a name="api_nan_escapable_handle_scope"></a> ### Nan::EscapableHandleScope Similar to [`Nan::HandleScope`](#api_nan_handle_scope) but should be used in cases where a function needs to return a V8 JavaScript type that has been created within it. Definition: ```c++ class Nan::EscapableHandleScope { public: Nan::EscapableHandleScope(); static int NumberOfHandles(); template<typename T> v8::Local<T> Escape(v8::Local<T> value); } ``` Use `Escape(value)` to return the object. Example: ```c++ v8::Local<v8::Object> EmptyObj() { Nan::EscapableHandleScope scope; v8::Local<v8::Object> obj = Nan::New<v8::Object>(); return scope.Escape(obj); } ```