Move app/server to flipper-server-core
Summary: moved `app/src/server` to `flipper-server-core/src` and fixed any fallout from that (aka integration points I missed on the preparing diffs). Reviewed By: passy Differential Revision: D31541378 fbshipit-source-id: 8a7e0169ebefa515781f6e5e0f7b926415d4b7e9
This commit is contained in:
committed by
Facebook GitHub Bot
parent
3e7a6b1b4b
commit
d88b28330a
27
desktop/flipper-server-core/src/comms/ClientConnection.tsx
Normal file
27
desktop/flipper-server-core/src/comms/ClientConnection.tsx
Normal file
@@ -0,0 +1,27 @@
|
||||
/**
|
||||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @format
|
||||
*/
|
||||
|
||||
import {ClientResponseType} from 'flipper-common';
|
||||
|
||||
export enum ConnectionStatus {
|
||||
ERROR = 'error',
|
||||
CLOSED = 'closed',
|
||||
CONNECTED = 'connected',
|
||||
NOT_CONNECTED = 'not_connected',
|
||||
CONNECTING = 'connecting',
|
||||
}
|
||||
|
||||
export type ConnectionStatusChange = (status: ConnectionStatus) => void;
|
||||
|
||||
export interface ClientConnection {
|
||||
subscribeToEvents(subscriber: ConnectionStatusChange): void;
|
||||
close(): void;
|
||||
send(data: any): void;
|
||||
sendExpectResponse(data: any): Promise<ClientResponseType>;
|
||||
}
|
||||
Reference in New Issue
Block a user