Chris@0: filename = $filename; Chris@0: $this->mode = $mode; Chris@0: } Chris@0: Chris@0: /** Chris@0: * Creates the underlying stream lazily when required. Chris@0: * Chris@0: * @return StreamInterface Chris@0: */ Chris@0: protected function createStream() Chris@0: { Chris@0: return stream_for(try_fopen($this->filename, $this->mode)); Chris@0: } Chris@0: }