From 4adfffae3487a6f677cda5a9eccc9b41cc34b406 Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=B4me=20Benoit?= Date: Sun, 18 Oct 2020 01:31:29 +0200 Subject: [PATCH] Fix configuration files. MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Jérôme Benoit --- docker/config.json | 12 +- flow-typed/npm/babel-eslint_vx.x.x.js | 4 +- flow-typed/npm/clinic_vx.x.x.js | 25 +- flow-typed/npm/eslint-config-google_vx.x.x.js | 4 +- flow-typed/npm/eslint-config-node_vx.x.x.js | 4 +- .../npm/eslint-plugin-flowtype_vx.x.x.js | 18 +- flow-typed/npm/eslint_vx.x.x.js | 53 +-- flow-typed/npm/flow-typed_vx.x.x.js | 4 +- flow-typed/npm/npm-check_vx.x.x.js | 4 +- flow-typed/npm/worker-threads-pool_vx.x.x.js | 4 +- flow-typed/npm/ws_v7.x.x.js | 363 ++++++++++++++++++ flow-typed/npm/ws_vx.x.x.js | 122 ------ package-lock.json | 6 +- package.json | 2 +- src/assets/config-template.json | 4 +- 15 files changed, 456 insertions(+), 173 deletions(-) create mode 100644 flow-typed/npm/ws_v7.x.x.js delete mode 100644 flow-typed/npm/ws_vx.x.x.js diff --git a/docker/config.json b/docker/config.json index 3181dfb4..3487a144 100644 --- a/docker/config.json +++ b/docker/config.json @@ -10,27 +10,27 @@ "workerPoolSize": 16, "stationTemplateURLs": [ { - "file": "./src/assets/station/siemens.mougins69.station", + "file": "./src/assets/station-templates/siemens.mougins69.station-template.json", "numberOfStation": 0 }, { - "file": "./src/assets/station/keba.station", + "file": "./src/assets/station-templates/keba.station-template.json", "numberOfStation": 0 }, { - "file": "./src/assets/station/abb.station", + "file": "./src/assets/station-templates/abb.station-template.json", "numberOfStation": 0 }, { - "file": "./src/assets/station/evlink.station", + "file": "./src/assets/station-templates/evlink.station-template.json", "numberOfStation": 0 }, { - "file": "./src/assets/station/schneider.station", + "file": "./src/assets/station-templates/schneider.station-template.json", "numberOfStation": 0 }, { - "file": "./src/assets/station/virtual-simple-atg.station", + "file": "./src/assets/station-templates/virtual-simple-atg.station-template.json", "numberOfStation": 10 } ], diff --git a/flow-typed/npm/babel-eslint_vx.x.x.js b/flow-typed/npm/babel-eslint_vx.x.x.js index feec5e79..05f52652 100644 --- a/flow-typed/npm/babel-eslint_vx.x.x.js +++ b/flow-typed/npm/babel-eslint_vx.x.x.js @@ -1,5 +1,5 @@ -// flow-typed signature: db1b92bd8ee2f327839575a430181d07 -// flow-typed version: <>/babel-eslint_v^10.1.0/flow_v0.125.1 +// flow-typed signature: 6334367253781eafb63df8d92be47d8d +// flow-typed version: <>/babel-eslint_v^10.1.0/flow_v0.136.0 /** * This is an autogenerated libdef stub for: diff --git a/flow-typed/npm/clinic_vx.x.x.js b/flow-typed/npm/clinic_vx.x.x.js index 4f68a686..7d649e02 100644 --- a/flow-typed/npm/clinic_vx.x.x.js +++ b/flow-typed/npm/clinic_vx.x.x.js @@ -1,5 +1,5 @@ -// flow-typed signature: faa74ccf0dffb83c451385e574b67bfd -// flow-typed version: <>/clinic_v^5.0.1/flow_v0.125.1 +// flow-typed signature: 7ce143f62e46f69c1f0d226420c51772 +// flow-typed version: <>/clinic_v^7.0.0/flow_v0.136.0 /** * This is an autogenerated libdef stub for: @@ -102,6 +102,10 @@ declare module 'clinic/test/cli-bubbleprof-no-args.test' { declare module.exports: any; } +declare module 'clinic/test/cli-bubbleprof-non-node.test' { + declare module.exports: any; +} + declare module 'clinic/test/cli-bubbleprof-version.test' { declare module.exports: any; } @@ -146,6 +150,10 @@ declare module 'clinic/test/cli-doctor-no-args.test' { declare module.exports: any; } +declare module 'clinic/test/cli-doctor-non-node.test' { + declare module.exports: any; +} + declare module 'clinic/test/cli-doctor-version.test' { declare module.exports: any; } @@ -166,6 +174,10 @@ declare module 'clinic/test/cli-flame-no-args.test' { declare module.exports: any; } +declare module 'clinic/test/cli-flame-non-node.test' { + declare module.exports: any; +} + declare module 'clinic/test/cli-flame-upload.test' { declare module.exports: any; } @@ -275,6 +287,9 @@ declare module 'clinic/test/cli-bubbleprof-help.test.js' { declare module 'clinic/test/cli-bubbleprof-no-args.test.js' { declare module.exports: $Exports<'clinic/test/cli-bubbleprof-no-args.test'>; } +declare module 'clinic/test/cli-bubbleprof-non-node.test.js' { + declare module.exports: $Exports<'clinic/test/cli-bubbleprof-non-node.test'>; +} declare module 'clinic/test/cli-bubbleprof-version.test.js' { declare module.exports: $Exports<'clinic/test/cli-bubbleprof-version.test'>; } @@ -308,6 +323,9 @@ declare module 'clinic/test/cli-doctor-help.test.js' { declare module 'clinic/test/cli-doctor-no-args.test.js' { declare module.exports: $Exports<'clinic/test/cli-doctor-no-args.test'>; } +declare module 'clinic/test/cli-doctor-non-node.test.js' { + declare module.exports: $Exports<'clinic/test/cli-doctor-non-node.test'>; +} declare module 'clinic/test/cli-doctor-version.test.js' { declare module.exports: $Exports<'clinic/test/cli-doctor-version.test'>; } @@ -323,6 +341,9 @@ declare module 'clinic/test/cli-flame-help.test.js' { declare module 'clinic/test/cli-flame-no-args.test.js' { declare module.exports: $Exports<'clinic/test/cli-flame-no-args.test'>; } +declare module 'clinic/test/cli-flame-non-node.test.js' { + declare module.exports: $Exports<'clinic/test/cli-flame-non-node.test'>; +} declare module 'clinic/test/cli-flame-upload.test.js' { declare module.exports: $Exports<'clinic/test/cli-flame-upload.test'>; } diff --git a/flow-typed/npm/eslint-config-google_vx.x.x.js b/flow-typed/npm/eslint-config-google_vx.x.x.js index 2cba0975..850c7cfd 100644 --- a/flow-typed/npm/eslint-config-google_vx.x.x.js +++ b/flow-typed/npm/eslint-config-google_vx.x.x.js @@ -1,5 +1,5 @@ -// flow-typed signature: bfc202ce9ae289597d929b79232bdbf0 -// flow-typed version: <>/eslint-config-google_v^0.14.0/flow_v0.125.1 +// flow-typed signature: 6d53b8beb7564f054aa77b01a0bdc854 +// flow-typed version: <>/eslint-config-google_v^0.14.0/flow_v0.136.0 /** * This is an autogenerated libdef stub for: diff --git a/flow-typed/npm/eslint-config-node_vx.x.x.js b/flow-typed/npm/eslint-config-node_vx.x.x.js index 7a87f7a6..439e5a7e 100644 --- a/flow-typed/npm/eslint-config-node_vx.x.x.js +++ b/flow-typed/npm/eslint-config-node_vx.x.x.js @@ -1,5 +1,5 @@ -// flow-typed signature: 8ae698fb75cf6d908e02d537ee07bff0 -// flow-typed version: <>/eslint-config-node_v^4.0.0/flow_v0.125.1 +// flow-typed signature: 266abab1324d9dc432f9945dfa50e622 +// flow-typed version: <>/eslint-config-node_v^4.1.0/flow_v0.136.0 /** * This is an autogenerated libdef stub for: diff --git a/flow-typed/npm/eslint-plugin-flowtype_vx.x.x.js b/flow-typed/npm/eslint-plugin-flowtype_vx.x.x.js index f6c99776..8e204c61 100644 --- a/flow-typed/npm/eslint-plugin-flowtype_vx.x.x.js +++ b/flow-typed/npm/eslint-plugin-flowtype_vx.x.x.js @@ -1,5 +1,5 @@ -// flow-typed signature: fb95bcf691003ae18475a4321a47d71b -// flow-typed version: <>/eslint-plugin-flowtype_v^5.1.0/flow_v0.125.1 +// flow-typed signature: 8758aa073e18e09c34d2f362252e3a67 +// flow-typed version: <>/eslint-plugin-flowtype_v^5.2.0/flow_v0.136.0 /** * This is an autogenerated libdef stub for: @@ -278,6 +278,14 @@ declare module 'eslint-plugin-flowtype/dist/utilities/isFlowFileAnnotation' { declare module.exports: any; } +declare module 'eslint-plugin-flowtype/dist/utilities/isNoFlowFile' { + declare module.exports: any; +} + +declare module 'eslint-plugin-flowtype/dist/utilities/isNoFlowFileAnnotation' { + declare module.exports: any; +} + declare module 'eslint-plugin-flowtype/dist/utilities/iterateFunctionNodes' { declare module.exports: any; } @@ -495,6 +503,12 @@ declare module 'eslint-plugin-flowtype/dist/utilities/isFlowFile.js' { declare module 'eslint-plugin-flowtype/dist/utilities/isFlowFileAnnotation.js' { declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/isFlowFileAnnotation'>; } +declare module 'eslint-plugin-flowtype/dist/utilities/isNoFlowFile.js' { + declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/isNoFlowFile'>; +} +declare module 'eslint-plugin-flowtype/dist/utilities/isNoFlowFileAnnotation.js' { + declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/isNoFlowFileAnnotation'>; +} declare module 'eslint-plugin-flowtype/dist/utilities/iterateFunctionNodes.js' { declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/iterateFunctionNodes'>; } diff --git a/flow-typed/npm/eslint_vx.x.x.js b/flow-typed/npm/eslint_vx.x.x.js index d776031a..ff8969c9 100644 --- a/flow-typed/npm/eslint_vx.x.x.js +++ b/flow-typed/npm/eslint_vx.x.x.js @@ -1,5 +1,5 @@ -// flow-typed signature: c9c9c76857819e1c18c1d7043360371c -// flow-typed version: <>/eslint_v^7.0.0/flow_v0.125.1 +// flow-typed signature: 87284ccc293a1202f0475fb0dde28ec3 +// flow-typed version: <>/eslint_v^7.11.0/flow_v0.136.0 /** * This is an autogenerated libdef stub for: @@ -34,10 +34,6 @@ declare module 'eslint/conf/default-cli-options' { declare module.exports: any; } -declare module 'eslint/conf/environments' { - declare module.exports: any; -} - declare module 'eslint/conf/eslint-all' { declare module.exports: any; } @@ -466,6 +462,10 @@ declare module 'eslint/lib/rules/id-blacklist' { declare module.exports: any; } +declare module 'eslint/lib/rules/id-denylist' { + declare module.exports: any; +} + declare module 'eslint/lib/rules/id-length' { declare module.exports: any; } @@ -834,6 +834,10 @@ declare module 'eslint/lib/rules/no-loop-func' { declare module.exports: any; } +declare module 'eslint/lib/rules/no-loss-of-precision' { + declare module.exports: any; +} + declare module 'eslint/lib/rules/no-magic-numbers' { declare module.exports: any; } @@ -942,6 +946,10 @@ declare module 'eslint/lib/rules/no-process-exit' { declare module.exports: any; } +declare module 'eslint/lib/rules/no-promise-executor-return' { + declare module.exports: any; +} + declare module 'eslint/lib/rules/no-proto' { declare module.exports: any; } @@ -1082,6 +1090,10 @@ declare module 'eslint/lib/rules/no-unneeded-ternary' { declare module.exports: any; } +declare module 'eslint/lib/rules/no-unreachable-loop' { + declare module.exports: any; +} + declare module 'eslint/lib/rules/no-unreachable' { declare module.exports: any; } @@ -1450,10 +1462,6 @@ declare module 'eslint/lib/shared/ast-utils' { declare module.exports: any; } -declare module 'eslint/lib/shared/config-ops' { - declare module.exports: any; -} - declare module 'eslint/lib/shared/config-validator' { declare module.exports: any; } @@ -1466,10 +1474,6 @@ declare module 'eslint/lib/shared/logging' { declare module.exports: any; } -declare module 'eslint/lib/shared/naming' { - declare module.exports: any; -} - declare module 'eslint/lib/shared/relative-module-resolver' { declare module.exports: any; } @@ -1556,9 +1560,6 @@ declare module 'eslint/conf/config-schema.js' { declare module 'eslint/conf/default-cli-options.js' { declare module.exports: $Exports<'eslint/conf/default-cli-options'>; } -declare module 'eslint/conf/environments.js' { - declare module.exports: $Exports<'eslint/conf/environments'>; -} declare module 'eslint/conf/eslint-all.js' { declare module.exports: $Exports<'eslint/conf/eslint-all'>; } @@ -1895,6 +1896,9 @@ declare module 'eslint/lib/rules/handle-callback-err.js' { declare module 'eslint/lib/rules/id-blacklist.js' { declare module.exports: $Exports<'eslint/lib/rules/id-blacklist'>; } +declare module 'eslint/lib/rules/id-denylist.js' { + declare module.exports: $Exports<'eslint/lib/rules/id-denylist'>; +} declare module 'eslint/lib/rules/id-length.js' { declare module.exports: $Exports<'eslint/lib/rules/id-length'>; } @@ -2174,6 +2178,9 @@ declare module 'eslint/lib/rules/no-lonely-if.js' { declare module 'eslint/lib/rules/no-loop-func.js' { declare module.exports: $Exports<'eslint/lib/rules/no-loop-func'>; } +declare module 'eslint/lib/rules/no-loss-of-precision.js' { + declare module.exports: $Exports<'eslint/lib/rules/no-loss-of-precision'>; +} declare module 'eslint/lib/rules/no-magic-numbers.js' { declare module.exports: $Exports<'eslint/lib/rules/no-magic-numbers'>; } @@ -2255,6 +2262,9 @@ declare module 'eslint/lib/rules/no-process-env.js' { declare module 'eslint/lib/rules/no-process-exit.js' { declare module.exports: $Exports<'eslint/lib/rules/no-process-exit'>; } +declare module 'eslint/lib/rules/no-promise-executor-return.js' { + declare module.exports: $Exports<'eslint/lib/rules/no-promise-executor-return'>; +} declare module 'eslint/lib/rules/no-proto.js' { declare module.exports: $Exports<'eslint/lib/rules/no-proto'>; } @@ -2360,6 +2370,9 @@ declare module 'eslint/lib/rules/no-unmodified-loop-condition.js' { declare module 'eslint/lib/rules/no-unneeded-ternary.js' { declare module.exports: $Exports<'eslint/lib/rules/no-unneeded-ternary'>; } +declare module 'eslint/lib/rules/no-unreachable-loop.js' { + declare module.exports: $Exports<'eslint/lib/rules/no-unreachable-loop'>; +} declare module 'eslint/lib/rules/no-unreachable.js' { declare module.exports: $Exports<'eslint/lib/rules/no-unreachable'>; } @@ -2639,9 +2652,6 @@ declare module 'eslint/lib/shared/ajv.js' { declare module 'eslint/lib/shared/ast-utils.js' { declare module.exports: $Exports<'eslint/lib/shared/ast-utils'>; } -declare module 'eslint/lib/shared/config-ops.js' { - declare module.exports: $Exports<'eslint/lib/shared/config-ops'>; -} declare module 'eslint/lib/shared/config-validator.js' { declare module.exports: $Exports<'eslint/lib/shared/config-validator'>; } @@ -2651,9 +2661,6 @@ declare module 'eslint/lib/shared/deprecation-warnings.js' { declare module 'eslint/lib/shared/logging.js' { declare module.exports: $Exports<'eslint/lib/shared/logging'>; } -declare module 'eslint/lib/shared/naming.js' { - declare module.exports: $Exports<'eslint/lib/shared/naming'>; -} declare module 'eslint/lib/shared/relative-module-resolver.js' { declare module.exports: $Exports<'eslint/lib/shared/relative-module-resolver'>; } diff --git a/flow-typed/npm/flow-typed_vx.x.x.js b/flow-typed/npm/flow-typed_vx.x.x.js index 44b45165..2dbc3ca8 100644 --- a/flow-typed/npm/flow-typed_vx.x.x.js +++ b/flow-typed/npm/flow-typed_vx.x.x.js @@ -1,5 +1,5 @@ -// flow-typed signature: e72d6be179566448708556a6b200567d -// flow-typed version: <>/flow-typed_v^3.1.0/flow_v0.125.1 +// flow-typed signature: 5e180472a76cccade6d1e63228aa20a7 +// flow-typed version: <>/flow-typed_v^3.2.1/flow_v0.136.0 /** * This is an autogenerated libdef stub for: diff --git a/flow-typed/npm/npm-check_vx.x.x.js b/flow-typed/npm/npm-check_vx.x.x.js index 1b7714be..6ff0e334 100644 --- a/flow-typed/npm/npm-check_vx.x.x.js +++ b/flow-typed/npm/npm-check_vx.x.x.js @@ -1,5 +1,5 @@ -// flow-typed signature: dccad34d79742984f46415e5fa7c1faa -// flow-typed version: <>/npm-check_v^5.9.2/flow_v0.125.1 +// flow-typed signature: 4d3109b77e0817da465392a8572a5b10 +// flow-typed version: <>/npm-check_v^5.9.2/flow_v0.136.0 /** * This is an autogenerated libdef stub for: diff --git a/flow-typed/npm/worker-threads-pool_vx.x.x.js b/flow-typed/npm/worker-threads-pool_vx.x.x.js index c84d5797..47fec497 100644 --- a/flow-typed/npm/worker-threads-pool_vx.x.x.js +++ b/flow-typed/npm/worker-threads-pool_vx.x.x.js @@ -1,5 +1,5 @@ -// flow-typed signature: 969a8eb17cd2cb030f883aa82330d221 -// flow-typed version: <>/worker-threads-pool_v^2.0.0/flow_v0.125.1 +// flow-typed signature: 6adddf428f4e46e1e3029b27fac03a36 +// flow-typed version: <>/worker-threads-pool_v^2.0.0/flow_v0.136.0 /** * This is an autogenerated libdef stub for: diff --git a/flow-typed/npm/ws_v7.x.x.js b/flow-typed/npm/ws_v7.x.x.js new file mode 100644 index 00000000..a5cafd7a --- /dev/null +++ b/flow-typed/npm/ws_v7.x.x.js @@ -0,0 +1,363 @@ +// flow-typed signature: cf710812f8fe053ca189786d3fa45067 +// flow-typed version: be32675b14/ws_v7.x.x/flow_>=v0.104.x + +declare type ws$PerMessageDeflateOptions = {| + serverNoContextTakeover?: boolean, + clientNoContextTakeover?: boolean, + serverMaxWindowBits?: boolean | number, + clientMaxWindowBits?: boolean | number, + zlibDeflateOptions?: zlib$options, + zlibInflateOptions?: zlib$options, + threshold?: number, + concurrencyLimit?: number, + isServer?: boolean, + maxPayload?: number, +|}; + +declare class ws$WebSocketServer extends events$EventEmitter { + /** + * Create a `WebSocketServer` instance. + */ + constructor( + options: {| + backlog?: number, + clientTracking?: boolean, + handleProtocols?: () => mixed, + host?: string, + maxPayload?: number, + noServer?: boolean, + path?: string, + perMessageDeflate?: boolean | ws$PerMessageDeflateOptions, + port: number, + server?: http$Server | https$Server, + verifyClient?: () => mixed, + |}, + callback?: () => mixed + ): this; + constructor( + options: {| + backlog?: number, + clientTracking?: boolean, + handleProtocols?: () => mixed, + host?: string, + maxPayload?: number, + noServer?: boolean, + path?: string, + perMessageDeflate?: boolean | ws$PerMessageDeflateOptions, + port?: number, + server: http$Server | https$Server, + verifyClient?: () => mixed, + |}, + callback?: () => mixed + ): this; + constructor( + options: {| + backlog?: number, + clientTracking?: boolean, + handleProtocols?: () => mixed, + host?: string, + maxPayload?: number, + noServer: boolean, + path?: string, + perMessageDeflate?: boolean | ws$PerMessageDeflateOptions, + port?: number, + server?: http$Server | https$Server, + verifyClient?: () => mixed, + |}, + callback?: () => mixed + ): this; + + /** + * Emitted when the server closes. + */ + on(event: 'close', () => mixed): this; + + /** + * Emitted when the handshake is complete. + */ + on( + event: 'connection', + (socket: ws$WebSocket, request: http$IncomingMessage<>) => mixed + ): this; + + /** + * Emitted when an error occurs on the underlying server. + */ + on(event: 'error', (error: Error) => mixed): this; + + /** + * Emitted before the response headers are written to the socket as part of + * the handshake. + */ + on( + event: 'headers', + (headers: Array, request: http$IncomingMessage<>) => mixed + ): this; + + /** + * Emitted when the underlying server has been bound. + */ + on(event: 'listening', () => mixed): this; + + /** + * Returns the bound address, the address family name, and port of the server + * as reported by the operating system if listening on an IP socket. + * If the server is listening on a pipe or UNIX domain socket, the name is + * returned as a string. + */ + address(): + | null + | string + | {| port?: number, family?: string, address?: string |}; + + /** + * A set that stores all connected clients. Please note that this property is + * only added when the `clientTracking` is truthy. + */ + clients: Set; + + /** + * Close the server. + */ + close(callback?: () => mixed): void; + + /** + * Handle a HTTP Upgrade request. + */ + handleUpgrade( + request: http$IncomingMessage<>, + socket: net$Socket, + head: Buffer, + callback: (?ws$WebSocket) => mixed + ): void; + + /** + * See if a given request should be handled by this server instance. + */ + shouldHandle(request: http$IncomingMessage<>): boolean; +} + +declare type ws$WebSocketOptions = { + followRedirects?: boolean, + handshakeTimeout?: number, + maxRedirects?: number, + perMessageDeflate?: boolean | ws$PerMessageDeflateOptions, + protocolVersion?: number, + origin?: string, + maxPayload?: number, + ...requestOptions, + agent?: boolean | http$Agent<> | http$Agent, + createConnection?: + | ((options: net$connectOptions, callback?: () => mixed) => net$Socket) + | ((options: tls$connectOptions, callback?: () => mixed) => tls$TLSSocket), + ... +}; + +declare type ws$CloseListener = (code: number, reason: string) => mixed; +declare type ws$ErrorListener = (error: Error) => mixed; +declare type ws$MessageListener = ( + data: string | Buffer | ArrayBuffer | Array +) => mixed; +declare type ws$OpenListener = () => mixed; +declare type ws$PingListener = (Buffer) => mixed; +declare type ws$PongListener = (Buffer) => mixed; +declare type ws$UnexpectedResponseListener = ( + request: http$ClientRequest<>, + response: http$IncomingMessage<> +) => mixed; +declare type ws$UpgradeListener = (response: http$IncomingMessage<>) => mixed; + +declare class ws$WebSocket extends events$EventEmitter { + static Server: typeof ws$WebSocketServer; + + static createWebSocketStream: ( + WebSocket: ws$WebSocket, + options?: duplexStreamOptions + ) => stream$Duplex; + + static CONNECTING: number; + static OPEN: number; + static CLOSING: number; + static CLOSED: number; + + /** + * Create a `WebSocket` instance. + */ + constructor( + address: string | URL, + protocols?: string | Array, + options?: ws$WebSocketOptions + ): this; + constructor(address: string | URL, options: ws$WebSocketOptions): this; + + /* + * Emitted when the connection is closed. + */ + on('close', ws$CloseListener): this; + + /* + * Emitted when an error occurs. + */ + on('error', ws$ErrorListener): this; + + /* + * Emitted when a message is received from the server. + */ + on('message', ws$MessageListener): this; + + /* + * Emitted when the connection is established. + */ + on('open', ws$OpenListener): this; + + /* + * Emitted when a ping is received from the server. + */ + on('ping', ws$PingListener): this; + + /* + * Emitted when a pong is received from the server. + */ + on('pong', ws$PongListener): this; + + /* + * Emitted when the server response is not the expected one, + * for example a 401 response. + */ + on('unexpected-response', ws$UnexpectedResponseListener): this; + + /* + * Emitted when response headers are received from the server as part of the + * handshake. + */ + on('upgrade', ws$UpgradeListener): this; + + /** + * Register an event listener emulating the `EventTarget` interface. + */ + addEventListener( + type: 'close', + listener: ws$CloseListener, + options?: {| once?: boolean |} + ): this; + addEventListener( + type: 'error', + listener: ws$ErrorListener, + options?: {| once?: boolean |} + ): this; + addEventListener( + type: 'message', + listener: ws$MessageListener, + options?: {| once?: boolean |} + ): this; + addEventListener( + type: 'open', + listener: ws$OpenListener, + options?: {| once?: boolean |} + ): this; + addEventListener( + type: 'ping', + listener: ws$PingListener, + options?: {| once?: boolean |} + ): this; + addEventListener( + type: 'pong', + listener: ws$PongListener, + options?: {| once?: boolean |} + ): this; + addEventListener( + type: 'unexpected-response', + ws$UnexpectedResponseListener, + options?: {| once?: boolean |} + ): this; + addEventListener( + type: 'upgrade', + listener: ws$UpgradeListener, + options?: {| once?: boolean |} + ): this; + + /** + * A string indicating the type of binary data being transmitted by the + * connection. + */ + binaryType: string; + + /** + * The number of bytes of data that have been queued using calls to send() + * but not yet transmitted to the network. + */ + bufferedAmount: number; + + /** + * Initiate a closing handshake. + */ + close(code?: number, reason?: string): void; + + /** + * The negotiated extensions. + */ + extensions: string; + + /** + * Send a ping. + */ + ping(data?: any, mask?: boolean, callback?: () => mixed): void; + ping(data: any, callback: () => mixed): void; + ping(callback: () => mixed): void; + + /** + * Send a pong. + */ + pong(data?: any, mask?: boolean, callback?: () => mixed): void; + pong(data: any, callback: () => mixed): void; + pong(callback: () => mixed): void; + + /** + * The subprotocol selected by the server. + */ + protocol: string; + + /** + * The current state of the connection. + */ + readyState: number; + + /** + * Removes an event listener emulating the `EventTarget` interface. + */ + removeEventListener(type: 'close', listener: ws$CloseListener): this; + removeEventListener(type: 'error', listener: ws$ErrorListener): this; + removeEventListener(type: 'message', listener: ws$MessageListener): this; + removeEventListener(type: 'open', listener: ws$OpenListener): this; + removeEventListener(type: 'ping', listener: ws$PingListener): this; + removeEventListener(type: 'pong', listener: ws$PongListener): this; + removeEventListener( + type: 'unexpected-response', + ws$UnexpectedResponseListener + ): this; + removeEventListener(type: 'upgrade', listener: ws$UpgradeListener): this; + + /** + * Send a data message. + */ + send( + data?: any, + options?: {| + compress?: boolean, + binary?: boolean, + mask?: boolean, + fin?: boolean, + |}, + callback?: () => mixed + ): void; + send(data: any, callback: () => mixed): void; + + /** + * Forcibly close the connection. + */ + terminate(): void; +} + +declare module 'ws' { + declare module.exports: typeof ws$WebSocket; +} diff --git a/flow-typed/npm/ws_vx.x.x.js b/flow-typed/npm/ws_vx.x.x.js deleted file mode 100644 index b0a96adb..00000000 --- a/flow-typed/npm/ws_vx.x.x.js +++ /dev/null @@ -1,122 +0,0 @@ -// flow-typed signature: 4af5edbe6edf658ab322e330297059b8 -// flow-typed version: <>/ws_v^7.3.0/flow_v0.125.1 - -/** - * This is an autogenerated libdef stub for: - * - * 'ws' - * - * Fill this stub out by replacing all the `any` types. - * - * Once filled out, we encourage you to share your work with the - * community by sending a pull request to: - * https://github.com/flowtype/flow-typed - */ - -declare module 'ws' { - declare module.exports: any; -} - -/** - * We include stubs for each file inside this npm package in case you need to - * require those files directly. Feel free to delete any files that aren't - * needed. - */ -declare module 'ws/browser' { - declare module.exports: any; -} - -declare module 'ws/lib/buffer-util' { - declare module.exports: any; -} - -declare module 'ws/lib/constants' { - declare module.exports: any; -} - -declare module 'ws/lib/event-target' { - declare module.exports: any; -} - -declare module 'ws/lib/extension' { - declare module.exports: any; -} - -declare module 'ws/lib/limiter' { - declare module.exports: any; -} - -declare module 'ws/lib/permessage-deflate' { - declare module.exports: any; -} - -declare module 'ws/lib/receiver' { - declare module.exports: any; -} - -declare module 'ws/lib/sender' { - declare module.exports: any; -} - -declare module 'ws/lib/stream' { - declare module.exports: any; -} - -declare module 'ws/lib/validation' { - declare module.exports: any; -} - -declare module 'ws/lib/websocket-server' { - declare module.exports: any; -} - -declare module 'ws/lib/websocket' { - declare module.exports: any; -} - -// Filename aliases -declare module 'ws/browser.js' { - declare module.exports: $Exports<'ws/browser'>; -} -declare module 'ws/index' { - declare module.exports: $Exports<'ws'>; -} -declare module 'ws/index.js' { - declare module.exports: $Exports<'ws'>; -} -declare module 'ws/lib/buffer-util.js' { - declare module.exports: $Exports<'ws/lib/buffer-util'>; -} -declare module 'ws/lib/constants.js' { - declare module.exports: $Exports<'ws/lib/constants'>; -} -declare module 'ws/lib/event-target.js' { - declare module.exports: $Exports<'ws/lib/event-target'>; -} -declare module 'ws/lib/extension.js' { - declare module.exports: $Exports<'ws/lib/extension'>; -} -declare module 'ws/lib/limiter.js' { - declare module.exports: $Exports<'ws/lib/limiter'>; -} -declare module 'ws/lib/permessage-deflate.js' { - declare module.exports: $Exports<'ws/lib/permessage-deflate'>; -} -declare module 'ws/lib/receiver.js' { - declare module.exports: $Exports<'ws/lib/receiver'>; -} -declare module 'ws/lib/sender.js' { - declare module.exports: $Exports<'ws/lib/sender'>; -} -declare module 'ws/lib/stream.js' { - declare module.exports: $Exports<'ws/lib/stream'>; -} -declare module 'ws/lib/validation.js' { - declare module.exports: $Exports<'ws/lib/validation'>; -} -declare module 'ws/lib/websocket-server.js' { - declare module.exports: $Exports<'ws/lib/websocket-server'>; -} -declare module 'ws/lib/websocket.js' { - declare module.exports: $Exports<'ws/lib/websocket'>; -} diff --git a/package-lock.json b/package-lock.json index 031c473a..d97ba748 100644 --- a/package-lock.json +++ b/package-lock.json @@ -4572,9 +4572,9 @@ "dev": true }, "flow-bin": { - "version": "0.135.0", - "resolved": "https://registry.npmjs.org/flow-bin/-/flow-bin-0.135.0.tgz", - "integrity": "sha512-E0JIKWopjULE/fl1X+j7rh0zgcgD5nubLs3HWYeYPo+nWFy8dALvrQbFcCFoPePrkhY/fffhN28t8P1zBxB2Yg==", + "version": "0.136.0", + "resolved": "https://registry.npmjs.org/flow-bin/-/flow-bin-0.136.0.tgz", + "integrity": "sha512-Z0sycQDyWXiNsGAhOBUrvHPzz7Q4g38BT57+YzZGffbaBmWRNC6MGZb+R6XTzeWb30bZin5V21nPQZezJzm9cQ==", "dev": true }, "flow-typed": { diff --git a/package.json b/package.json index 6b9ffdc4..59fe0ea6 100644 --- a/package.json +++ b/package.json @@ -50,7 +50,7 @@ "eslint-config-google": "^0.14.0", "eslint-config-node": "^4.1.0", "eslint-plugin-flowtype": "^5.2.0", - "flow-bin": "^0.135.0", + "flow-bin": "^0.136.0", "flow-typed": "^3.2.1", "npm-check": "^5.9.2" } diff --git a/src/assets/config-template.json b/src/assets/config-template.json index 60f1d2d1..831f88da 100644 --- a/src/assets/config-template.json +++ b/src/assets/config-template.json @@ -10,11 +10,11 @@ "workerPoolSize": 16, "stationTemplateURLs": [ { - "file": "./src/assets/station-templates/siemens.mougins69.station-template.json-template.json", + "file": "./src/assets/station-templates/siemens.mougins69.station-template.json", "numberOfStation": 1 }, { - "file": "./src/assets/station-templates/keba.station-template.json-template.json", + "file": "./src/assets/station-templates/keba.station-template.json", "numberOfStation": 2 }, { -- 2.34.1