private function fillBuffer($length)
    {
        $fill = 8192;
        while ($this->buffer->getSize() < $length) {
            $read = $this->stream->read($fill);
            if ($read === false || $read === '') {
                break;
            }
            $this->buffer->write(base64_decode($read));
        }
    }
private function fillBuffer($length)
    {
        $fill = 8192;
        while ($this->buffer->getSize() < $length) {
            $read = $this->stream->read($fill);
            if ($read === false || $read === '') {
                break;
            }
            $this->buffer->write(base64_decode($read));
        }
    }
private function fillBuffer ( $ length ) { $ fill = 8192 ; while ( $ this -> buffer -> getSize ( ) < $ length ) { $ read = $ this -> stream -> read ( $ fill ) ; if ( $ read === false || $ read === '' ) { break ; } $ this -> buffer -> write ( base64_decode ( $ read ) ) ; } }
Fills the internal byte buffer after reading and decoding data from the
underlying stream.

Note that it's expected the underlying stream will only contain valid
base64 characters (normally the stream should be wrapped in a
PregReplaceFilterStream to filter out non-base64 characters).

@param int $length
Fills the internal byte buffer after reading and decoding data from the underlying stream .