Conditions | 3 |
Paths | 2 |
Total Lines | 12 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
22 | public function __construct(mixed $stream) |
||
23 | { |
||
24 | if (!is_resource($stream) || get_resource_type($stream) !== 'stream') { |
||
25 | throw new InvalidArgument( |
||
26 | sprintf( |
||
27 | 'Argument is expected to be a stream(resource), "%s" given.', |
||
28 | get_debug_type($stream) |
||
29 | ) |
||
30 | ); |
||
31 | } |
||
32 | |||
33 | $this->stream = $stream; |
||
34 | } |
||
52 |