2023-03-05 19:57:05 +01:00
|
|
|
import http from "http"
|
|
|
|
import Koa from "koa"
|
|
|
|
import ClientAppSocket from "./client"
|
2023-05-16 15:18:31 +02:00
|
|
|
import GridSocket from "./grid"
|
|
|
|
import BuilderSocket from "./builder"
|
2023-03-05 19:57:05 +01:00
|
|
|
|
|
|
|
let clientAppSocket: ClientAppSocket
|
2023-04-20 09:02:49 +02:00
|
|
|
let gridSocket: GridSocket
|
2023-05-16 15:18:31 +02:00
|
|
|
let builderSocket: BuilderSocket
|
2023-03-05 19:57:05 +01:00
|
|
|
|
|
|
|
export const initialise = (app: Koa, server: http.Server) => {
|
|
|
|
clientAppSocket = new ClientAppSocket(app, server)
|
2023-04-20 09:02:49 +02:00
|
|
|
gridSocket = new GridSocket(app, server)
|
2023-05-16 15:18:31 +02:00
|
|
|
builderSocket = new BuilderSocket(app, server)
|
2023-03-05 19:57:05 +01:00
|
|
|
}
|
|
|
|
|
2023-05-22 16:59:44 +02:00
|
|
|
export { clientAppSocket, gridSocket, builderSocket }
|