|
@@ -19,19 +19,23 @@ import static io.undertow.Handlers.*;
|
19
|
19
|
|
20
|
20
|
public class CuisineHTTPServer extends Thread
|
21
|
21
|
{
|
22
|
|
- final int webPagePort = 8080;
|
|
22
|
+ static int webPagePort = 8080;
|
23
|
23
|
|
24
|
|
- final int webSocketPort = 42069;
|
25
|
|
- final String webSocketHost = "192.168.0.24";
|
|
24
|
+ static int webSocketPort = 42069;
|
|
25
|
+ static String webSocketHost = "192.168.0.24";
|
26
|
26
|
|
27
|
|
- final int tcpSocketPort = 6868;
|
28
|
|
- final String HOST = "0.0.0.0" ;
|
|
27
|
+ static int tcpSocketPort = 6868;
|
|
28
|
+ static String HOST = "0.0.0.0" ;
|
29
|
29
|
|
30
|
30
|
|
31
|
31
|
private static CuisineTCPServer fCuisineTCPServer;
|
32
|
32
|
|
33
|
|
- public void startServer()
|
|
33
|
+ public void startServer(String iHostName, int iWebPagePort, int iWebSocketPort, int iTcpSocketPort)
|
34
|
34
|
{
|
|
35
|
+ webSocketHost = iHostName;
|
|
36
|
+ webPagePort = iWebPagePort;
|
|
37
|
+ webSocketPort = iWebSocketPort;
|
|
38
|
+ tcpSocketPort = iTcpSocketPort;
|
35
|
39
|
initResources();
|
36
|
40
|
|
37
|
41
|
//Create CuisineTCPServers
|
|
@@ -141,7 +145,7 @@ public class CuisineHTTPServer extends Thread
|
141
|
145
|
.append(" </style>")
|
142
|
146
|
.append("</head>")
|
143
|
147
|
.append("<body>")
|
144
|
|
- .append(" <div class=\"pre\">")
|
|
148
|
+ .append(" <div class=\"centered\">")
|
145
|
149
|
.append(sHtml_ASCII_title)
|
146
|
150
|
.append(" </div>")
|
147
|
151
|
.append(" <h1 id=\"tempValue\">None</h1>")
|