src: remove unused checkMessagePort
internal binding
PR-URL: https://github.com/nodejs/node/pull/58267 Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Darshan Sen <raisinten@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Ulises Gascón <ulisesgascongonzalez@gmail.com> Reviewed-By: Chengzhong Wu <legendecas@gmail.com>
This commit is contained in:
parent
200abfc43e
commit
6dcd4621bd
@ -1141,13 +1141,6 @@ void MessagePort::Stop(const FunctionCallbackInfo<Value>& args) {
|
|||||||
port->Stop();
|
port->Stop();
|
||||||
}
|
}
|
||||||
|
|
||||||
void MessagePort::CheckType(const FunctionCallbackInfo<Value>& args) {
|
|
||||||
Environment* env = Environment::GetCurrent(args);
|
|
||||||
args.GetReturnValue().Set(
|
|
||||||
GetMessagePortConstructorTemplate(env->isolate_data())
|
|
||||||
->HasInstance(args[0]));
|
|
||||||
}
|
|
||||||
|
|
||||||
void MessagePort::Drain(const FunctionCallbackInfo<Value>& args) {
|
void MessagePort::Drain(const FunctionCallbackInfo<Value>& args) {
|
||||||
MessagePort* port;
|
MessagePort* port;
|
||||||
ASSIGN_OR_RETURN_UNWRAP(&port, args[0].As<Object>());
|
ASSIGN_OR_RETURN_UNWRAP(&port, args[0].As<Object>());
|
||||||
@ -1731,7 +1724,6 @@ static void CreatePerIsolateProperties(IsolateData* isolate_data,
|
|||||||
// These are not methods on the MessagePort prototype, because
|
// These are not methods on the MessagePort prototype, because
|
||||||
// the browser equivalents do not provide them.
|
// the browser equivalents do not provide them.
|
||||||
SetMethod(isolate, target, "stopMessagePort", MessagePort::Stop);
|
SetMethod(isolate, target, "stopMessagePort", MessagePort::Stop);
|
||||||
SetMethod(isolate, target, "checkMessagePort", MessagePort::CheckType);
|
|
||||||
SetMethod(isolate, target, "drainMessagePort", MessagePort::Drain);
|
SetMethod(isolate, target, "drainMessagePort", MessagePort::Drain);
|
||||||
SetMethod(
|
SetMethod(
|
||||||
isolate, target, "receiveMessageOnPort", MessagePort::ReceiveMessage);
|
isolate, target, "receiveMessageOnPort", MessagePort::ReceiveMessage);
|
||||||
@ -1767,7 +1759,6 @@ static void RegisterExternalReferences(ExternalReferenceRegistry* registry) {
|
|||||||
registry->Register(MessagePort::PostMessage);
|
registry->Register(MessagePort::PostMessage);
|
||||||
registry->Register(MessagePort::Start);
|
registry->Register(MessagePort::Start);
|
||||||
registry->Register(MessagePort::Stop);
|
registry->Register(MessagePort::Stop);
|
||||||
registry->Register(MessagePort::CheckType);
|
|
||||||
registry->Register(MessagePort::Drain);
|
registry->Register(MessagePort::Drain);
|
||||||
registry->Register(MessagePort::ReceiveMessage);
|
registry->Register(MessagePort::ReceiveMessage);
|
||||||
registry->Register(MessagePort::MoveToContext);
|
registry->Register(MessagePort::MoveToContext);
|
||||||
|
@ -261,7 +261,6 @@ class MessagePort : public HandleWrap {
|
|||||||
static void PostMessage(const v8::FunctionCallbackInfo<v8::Value>& args);
|
static void PostMessage(const v8::FunctionCallbackInfo<v8::Value>& args);
|
||||||
static void Start(const v8::FunctionCallbackInfo<v8::Value>& args);
|
static void Start(const v8::FunctionCallbackInfo<v8::Value>& args);
|
||||||
static void Stop(const v8::FunctionCallbackInfo<v8::Value>& args);
|
static void Stop(const v8::FunctionCallbackInfo<v8::Value>& args);
|
||||||
static void CheckType(const v8::FunctionCallbackInfo<v8::Value>& args);
|
|
||||||
static void Drain(const v8::FunctionCallbackInfo<v8::Value>& args);
|
static void Drain(const v8::FunctionCallbackInfo<v8::Value>& args);
|
||||||
static void ReceiveMessage(const v8::FunctionCallbackInfo<v8::Value>& args);
|
static void ReceiveMessage(const v8::FunctionCallbackInfo<v8::Value>& args);
|
||||||
|
|
||||||
|
1
typings/internalBinding/messaging.d.ts
vendored
1
typings/internalBinding/messaging.d.ts
vendored
@ -23,7 +23,6 @@ export interface MessagingBinding {
|
|||||||
MessagePort: typeof InternalMessagingBinding.MessagePort;
|
MessagePort: typeof InternalMessagingBinding.MessagePort;
|
||||||
JSTransferable: typeof InternalMessagingBinding.JSTransferable;
|
JSTransferable: typeof InternalMessagingBinding.JSTransferable;
|
||||||
stopMessagePort(port: typeof InternalMessagingBinding.MessagePort): void;
|
stopMessagePort(port: typeof InternalMessagingBinding.MessagePort): void;
|
||||||
checkMessagePort(port: unknown): boolean;
|
|
||||||
drainMessagePort(port: typeof InternalMessagingBinding.MessagePort): void;
|
drainMessagePort(port: typeof InternalMessagingBinding.MessagePort): void;
|
||||||
receiveMessageOnPort(port: typeof InternalMessagingBinding.MessagePort): any;
|
receiveMessageOnPort(port: typeof InternalMessagingBinding.MessagePort): any;
|
||||||
moveMessagePortToContext(port: typeof InternalMessagingBinding.MessagePort, context: any): typeof InternalMessagingBinding.MessagePort;
|
moveMessagePortToContext(port: typeof InternalMessagingBinding.MessagePort, context: any): typeof InternalMessagingBinding.MessagePort;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user