public function rewind()
    {
        if ($this->isOpen() === false) {
            $msg = "Cannot call rewind() on a closed MemoryStream.";
            throw new MemoryStreamException($msg, $this, MemoryStreamException::NOT_OPEN);
        }

        $this->setPosition(0);
    }