private function beforeClose()
    {
        if ($this->isWritable() && $this->remainder !== '') {
            $this->stream->write(base64_encode($this->remainder));
            $this->remainder = '';
        }
    }
private function beforeClose()
    {
        if ($this->isWritable() && $this->remainder !== '') {
            $this->stream->write(base64_encode($this->remainder));
            $this->remainder = '';
        }
    }
private function beforeClose ( ) { if ( $ this -> isWritable ( ) && $ this -> remainder !== '' ) { $ this -> stream -> write ( base64_encode ( $ this -> remainder ) ) ; $ this -> remainder = '' ; } }
Writes out any remaining bytes at the end of the stream and closes.
Writes out any remaining bytes at the end of the stream and closes .