private static function serializeRequestException(RequestException $e)
    {
        $resultString = sprintf("Reason:\n%s\n", $e);
        if ($e->hasResponse()) {
            $resultString .= self::serializeResponse($e->getResponse());
        }

        return $resultString;
    }
private static function serializeRequestException(RequestException $e)
    {
        $resultString = sprintf("Reason:\n%s\n", $e);
        if ($e->hasResponse()) {
            $resultString .= self::serializeResponse($e->getResponse());
        }

        return $resultString;
    }
private static function serializeRequestException ( RequestException $ e ) { $ resultString = sprintf ( "Reason:\n%s\n" , $ e ) ; if ( $ e -> hasResponse ( ) ) { $ resultString .= self :: serializeResponse ( $ e -> getResponse ( ) ) ; } return $ resultString ; }
Serialize the request exception.

@param  RequestException $e the request exception to be serialized.

@return string
Serialize the request exception .