void FiberBase::start() { m_caller = JSFiber::current(); if (m_caller) { v8::Local<v8::Object> co = m_caller->wrap(); v8::Local<v8::Object> o = wrap(); v8::Local<v8::Array> ks = co->GetOwnPropertyNames(); int len = ks->Length(); int i; for (i = 0; i < len; i++) { v8::Local<v8::Value> k = ks->Get(i); o->Set(k, co->Get(k)); } } g_jobs.put(this); Ref(); }
void AsyncEvent::sync() { g_jobs.put(this); }
void FiberBase::start() { set_caller(JSFiber::current()); g_jobs.put(this); Ref(); }
void asyncCallBack::callback() { g_jobs.put(this); }