microsoft/vscode-react-native

Public

mirrored from https://github.com/microsoft/vscode-react-nativeAvailable

CodeCommitsIssuesPull requestsActionsInsightsSecurity
1.1.0

Branches

Tags

  • No tags available.
0Branches0Tags
Go to file
Add file
Code

Clone

HTTPS

Download ZIP

src/cdp-proxy/CDPMessageHandlers/baseCDPMessageHandler.ts

34lines · modeblame

259c018fYuri Skorokhodov5 years ago1// Copyright (c) Microsoft Corporation. All rights reserved.
2// Licensed under the MIT license. See LICENSE file in the project root for details.
3
4import { ICDPMessageHandler, ProcessedCDPMessage } from "./ICDPMessageHandler";
5import { Connection } from "vscode-cdp-proxy";
6
7export abstract class BaseCDPMessageHandler implements ICDPMessageHandler {
8protected debuggerTarget: Connection | null;
9protected applicationTarget: Connection | null;
10
11constructor() {}
12
13public processDebuggerCDPMessage(event: any): ProcessedCDPMessage {
14return {
15event,
16sendBack: false,
17};
18}
19
20public processApplicationCDPMessage(event: any): ProcessedCDPMessage {
21return {
22event,
23sendBack: false,
24};
25}
26
27public setDebuggerTarget(debuggerTarget: Connection | null): void {
28this.debuggerTarget = debuggerTarget;
29}
30
31public setApplicationTarget(applicationTarget: Connection | null): void {
32this.applicationTarget = applicationTarget;
33}
34}