Conditions | 3 |
Paths | 3 |
Total Lines | 13 |
Code Lines | 9 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
20 | public function read() |
||
21 | { |
||
22 | $stream = $this->getStream(); |
||
23 | if ($this->blocking) { |
||
24 | $read = [$stream]; |
||
25 | $write = []; |
||
26 | $except = []; |
||
27 | if (stream_select($read, $write, $except, null) > 0) { |
||
28 | return stream_get_contents($stream); |
||
29 | } |
||
30 | } |
||
31 | return stream_get_contents($stream); |
||
32 | } |
||
33 | |||
52 |