Lines Matching defs:args
40 static void New(const FunctionCallbackInfo<Value>& args);
41 static void EmitReceived(const FunctionCallbackInfo<Value>& args);
42 static void OnSendDone(const FunctionCallbackInfo<Value>& args);
43 static void OnAfterBind(const FunctionCallbackInfo<Value>& args);
110 Local<Value> args[] = {
116 if (!MakeCallback(env()->onwrite_string(), arraysize(args), args)
137 void JSUDPWrap::New(const FunctionCallbackInfo<Value>& args) {
138 Environment* env = Environment::GetCurrent(args);
139 CHECK(args.IsConstructCall());
140 new JSUDPWrap(env, args.Holder());
143 void JSUDPWrap::EmitReceived(const FunctionCallbackInfo<Value>& args) {
145 ASSIGN_OR_RETURN_UNWRAP(&wrap, args.Holder());
148 ArrayBufferViewContents<char> buffer(args[0]);
152 CHECK(args[1]->IsInt32()); // family
153 CHECK(args[2]->IsString()); // address
154 CHECK(args[3]->IsInt32()); // port
155 CHECK(args[4]->IsInt32()); // flags
156 int family = args[1].As<Int32>()->Value() == 4 ? AF_INET : AF_INET6;
157 Utf8Value address(env->isolate(), args[2]);
158 int port = args[3].As<Int32>()->Value();
159 int flags = args[3].As<Int32>()->Value();
177 void JSUDPWrap::OnSendDone(const FunctionCallbackInfo<Value>& args) {
179 ASSIGN_OR_RETURN_UNWRAP(&wrap, args.Holder());
181 CHECK(args[0]->IsObject());
182 CHECK(args[1]->IsInt32());
184 ASSIGN_OR_RETURN_UNWRAP(&req_wrap, args[0].As<Object>());
185 int status = args[1].As<Int32>()->Value();
190 void JSUDPWrap::OnAfterBind(const FunctionCallbackInfo<Value>& args) {
192 ASSIGN_OR_RETURN_UNWRAP(&wrap, args.Holder());