filename = $filename; $this->mode = $mode; } /** * Creates the underlying stream lazily when required. * * @return StreamInterface */ protected function createStream() { return Stream::factory(Utils::open($this->filename, $this->mode)); } }