public function dispatchResponse($response)
    {
        $parts = explode("\r\n\r\n", $response, 2);

        if (count($parts) < 2) {
            $this->throwException();
        }

        list($headersAsString, $body) = $parts;

        $headers = explode("\r\n", $headersAsString);
        list($code, $status) = $this->dispatchHttpStatus(array_shift($headers));
        $headers = $this->dispatchHeaders($headers);

        /** @var Emagedev_Utils_Model_Curl_Response $responseObject */
        $responseObject = Mage::getModel('emagedev_utils/curl_response');

        return $responseObject->setData(
            array(
                'code' => $code,
                'status' => $status,
                'headers_as_string' => $headersAsString,
                'headers' => $headers,
                'body' => $body
            )
        );
    }