1 | <?php |
||
25 | class StreamWriter extends AbstractWriter |
||
26 | { |
||
27 | /** |
||
28 | * The stream resource handle |
||
29 | * |
||
30 | * @var resource |
||
31 | */ |
||
32 | private $stream = null; |
||
33 | |||
34 | /** |
||
35 | * Constructs a new stream writer instance. |
||
36 | * |
||
37 | * @param resource|string $streamResourceOrUri |
||
38 | */ |
||
39 | 4 | public function __construct($streamResourceOrUri) |
|
56 | |||
57 | /** |
||
58 | * The dtor closes the open output resource. |
||
59 | */ |
||
60 | 4 | public function __destruct() |
|
67 | |||
68 | /** |
||
69 | * Writes the given <b>$data</b> fragment to the wrapper output stream. |
||
70 | * |
||
71 | * @param string $data |
||
72 | * @return void |
||
73 | */ |
||
74 | 4 | public function write($data) |
|
78 | } |
||
79 |
If you suppress an error, we recommend checking for the error condition explicitly: