Lines Matching defs:isolate
23 Local<Value> ErrnoException(Isolate* isolate,
28 Environment* env = Environment::GetCurrent(isolate);
32 Local<String> estring = OneByteString(isolate, errors::errno_string(errorno));
36 Local<String> message = OneByteString(isolate, msg);
39 String::Concat(isolate, estring, FIXED_ONE_BYTE_STRING(isolate, ", "));
40 cons = String::Concat(isolate, cons, message);
45 path_string = String::NewFromUtf8(isolate, path).ToLocalChecked();
49 cons = String::Concat(isolate, cons, FIXED_ONE_BYTE_STRING(isolate, " '"));
50 cons = String::Concat(isolate, cons, path_string);
51 cons = String::Concat(isolate, cons, FIXED_ONE_BYTE_STRING(isolate, "'"));
59 Integer::New(isolate, errorno)).Check();
69 OneByteString(isolate, syscall)).Check();
75 static Local<String> StringFromPath(Isolate* isolate, const char* path) {
79 isolate,
80 FIXED_ONE_BYTE_STRING(isolate, "\\\\"),
81 String::NewFromUtf8(isolate, path + 8).ToLocalChecked());
83 return String::NewFromUtf8(isolate, path + 4).ToLocalChecked();
87 return String::NewFromUtf8(isolate, path).ToLocalChecked();
91 Local<Value> UVException(Isolate* isolate,
97 Environment* env = Environment::GetCurrent(isolate);
103 Local<String> js_code = OneByteString(isolate, uv_err_name(errorno));
104 Local<String> js_syscall = OneByteString(isolate, syscall);
110 String::Concat(isolate, js_msg, FIXED_ONE_BYTE_STRING(isolate, ": "));
111 js_msg = String::Concat(isolate, js_msg, OneByteString(isolate, msg));
113 String::Concat(isolate, js_msg, FIXED_ONE_BYTE_STRING(isolate, ", "));
114 js_msg = String::Concat(isolate, js_msg, js_syscall);
117 js_path = StringFromPath(isolate, path);
120 String::Concat(isolate, js_msg, FIXED_ONE_BYTE_STRING(isolate, " '"));
121 js_msg = String::Concat(isolate, js_msg, js_path);
123 String::Concat(isolate, js_msg, FIXED_ONE_BYTE_STRING(isolate, "'"));
127 js_dest = StringFromPath(isolate, dest);
130 isolate, js_msg, FIXED_ONE_BYTE_STRING(isolate, " -> '"));
131 js_msg = String::Concat(isolate, js_msg, js_dest);
133 String::Concat(isolate, js_msg, FIXED_ONE_BYTE_STRING(isolate, "'"));
137 Exception::Error(js_msg)->ToObject(isolate->GetCurrentContext())
143 Integer::New(isolate, errorno)).Check();
187 Local<Value> WinapiErrnoException(Isolate* isolate,
192 Environment* env = Environment::GetCurrent(isolate);
199 Local<String> message = OneByteString(isolate, msg);
203 String::Concat(isolate, message, FIXED_ONE_BYTE_STRING(isolate, " '"));
205 isolate,
207 String::NewFromUtf8(isolate, path).ToLocalChecked());
209 String::Concat(isolate, cons2, FIXED_ONE_BYTE_STRING(isolate, "'"));
217 obj->Set(context, env->errno_string(), Integer::New(isolate, errorno))
223 String::NewFromUtf8(isolate, path).ToLocalChecked())
230 OneByteString(isolate, syscall))
246 void FatalException(Isolate* isolate, const v8::TryCatch& try_catch) {
247 errors::TriggerUncaughtException(isolate, try_catch);