CloudException.CreateFromXml 方法

Creates a CloudException from a failed response that was sent using XML.

命名空间: Microsoft.WindowsAzure
程序集: Microsoft.WindowsAzure.Common(在 Microsoft.WindowsAzure.Common.dll 中)

使用

用法
Dim request As HttpRequestMessage
Dim requestContent As String
Dim response As HttpResponseMessage
Dim responseContent As String
Dim innerException As Exception
Dim returnValue As CloudException

returnValue = CloudException.CreateFromXml(request, requestContent, response, responseContent, innerException)

语法

声明
<ObsoleteAttribute("This method is obsolete. Use Create without defaultTo parameter.")> _
Public Shared Function CreateFromXml ( _
    request As HttpRequestMessage, _
    requestContent As String, _
    response As HttpResponseMessage, _
    responseContent As String, _
    <OptionalAttribute> Optional innerException As Exception = Nothing _
) As CloudException
[ObsoleteAttribute("This method is obsolete. Use Create without defaultTo parameter.")] 
public static CloudException CreateFromXml (
    HttpRequestMessage request,
    string requestContent,
    HttpResponseMessage response,
    string responseContent,
    [OptionalAttribute] Exception innerException
)
[ObsoleteAttribute(L"This method is obsolete. Use Create without defaultTo parameter.")] 
public:
static CloudException^ CreateFromXml (
    HttpRequestMessage^ request, 
    String^ requestContent, 
    HttpResponseMessage^ response, 
    String^ responseContent, 
    [OptionalAttribute] Exception^ innerException
)
/** @attribute ObsoleteAttribute("This method is obsolete. Use Create without defaultTo parameter.") */ 
public static CloudException CreateFromXml (
    HttpRequestMessage request, 
    String requestContent, 
    HttpResponseMessage response, 
    String responseContent, 
    /** @attribute OptionalAttribute() */ Exception innerException
)
ObsoleteAttribute("This method is obsolete. Use Create without defaultTo parameter.") 
public static function CreateFromXml (
    request : HttpRequestMessage, 
    requestContent : String, 
    response : HttpResponseMessage, 
    responseContent : String, 
    innerException : Exception
) : CloudException

参数

  • request
    The HTTP request.
  • requestContent
    The HTTP request content.
  • response
    The HTTP response.
  • responseContent
    The HTTP response content.
  • innerException
    The inner exception.

返回值

A CloudException that represents the failure.

线程安全

此类型的所有公开静态(在 Visual Basic 中为共享)成员均为线程安全型成员。但不保证所有实例成员都是线程安全的。

平台

开发平台

Windows Vista、Windows 7 和 Windows Server 2008

目标平台

另请参阅

参考

CloudException 类
CloudException 成员
Microsoft.WindowsAzure 命名空间