MCPcopy Create free account
hub / github.com/nodejs/nan / AfterDelay

Function AfterDelay

test/cpp/callbackcontext.cpp:35–46  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

33}
34
35void AfterDelay(uv_work_t* req, int status) {
36 HandleScope scope;
37
38 DelayRequest *delay_request = static_cast<DelayRequest*>(req->data);
39
40 v8::Local<v8::Object> target = New<v8::Object>();
41
42 // Run the callback in the async context.
43 delay_request->callback.Call(target, 0, NULL, delay_request);
44
45 delete delay_request;
46}
47
48NAN_METHOD(Delay) {
49 int delay = To<int>(info[0]).FromJust();

Callers

nothing calls this directly

Calls 1

CallMethod · 0.80

Tested by

no test coverage detected