1 | <?php |
||
7 | class ServerConfig |
||
8 | { |
||
9 | |||
10 | private $clientsPerFork = WebSocketServerContract::CLIENTS_PER_FORK; |
||
11 | private $streamSelectTimeout = WebSocketServerContract::STREAM_SELECT_TIMEOUT; |
||
12 | |||
13 | private $host = WebSocketServerContract::DEFAULT_HOST; |
||
14 | private $port = WebSocketServerContract::DEFAULT_PORT; |
||
15 | |||
16 | /** |
||
17 | * @return mixed |
||
18 | */ |
||
19 | public function getClientsPerFork(): int |
||
23 | |||
24 | /** |
||
25 | * @param mixed $clientsPerFork |
||
26 | */ |
||
27 | public function setClientsPerFork(int $clientsPerFork) |
||
31 | |||
32 | /** |
||
33 | * @return mixed |
||
34 | */ |
||
35 | public function getStreamSelectTimeout(): int |
||
39 | |||
40 | /** |
||
41 | * @param mixed $streamSelectTimeout |
||
42 | */ |
||
43 | public function setStreamSelectTimeout(int $streamSelectTimeout) |
||
47 | |||
48 | /** |
||
49 | * @return string |
||
50 | */ |
||
51 | public function getHost(): string |
||
55 | |||
56 | /** |
||
57 | * @param string $host |
||
58 | */ |
||
59 | public function setHost(string $host) |
||
63 | |||
64 | /** |
||
65 | * @return int |
||
66 | */ |
||
67 | public function getPort(): int |
||
71 | |||
72 | /** |
||
73 | * @param int $port |
||
74 | */ |
||
75 | public function setPort(int $port) |
||
79 | } |