Total Complexity | 3 |
Total Lines | 35 |
Duplicated Lines | 0 % |
Changes | 3 | ||
Bugs | 1 | Features | 0 |
1 | <?php |
||
8 | class MockableConnection implements ConnectionInterface |
||
9 | { |
||
10 | /** |
||
11 | * Create a new Mockable connection. |
||
12 | * |
||
13 | * @param string|int $appId |
||
14 | * @param string $socketId |
||
15 | * @return void |
||
16 | */ |
||
17 | public function __construct($appId, string $socketId) |
||
18 | { |
||
19 | $this->app = new stdClass; |
||
|
|||
20 | |||
21 | $this->app->id = $appId; |
||
22 | $this->socketId = $socketId; |
||
23 | } |
||
24 | |||
25 | /** |
||
26 | * Send data to the connection. |
||
27 | * |
||
28 | * @param string $data |
||
29 | * @return \Ratchet\ConnectionInterface |
||
30 | */ |
||
31 | public function send($data) |
||
32 | { |
||
33 | // |
||
34 | } |
||
35 | |||
36 | /** |
||
37 | * Close the connection. |
||
38 | * |
||
39 | * @return void |
||
40 | */ |
||
41 | public function close() |
||
43 | // |
||
44 | } |
||
45 | } |
||
46 |