WebClientAsyncResult 类

定义

提供 IAsyncResult 的实现以供 XML Web services 代理使用来实现标准的异步方法模式。Provides an implementation of IAsyncResult for use by XML Web service proxies to implement the standard asynchronous method pattern.

public ref class WebClientAsyncResult : IAsyncResult
public class WebClientAsyncResult : IAsyncResult
type WebClientAsyncResult = class
    interface IAsyncResult
Public Class WebClientAsyncResult
Implements IAsyncResult
继承
WebClientAsyncResult
实现

注解

当你在 XML Web service BeginMyMethodName代理类上MyMethodName调用方法 (其中是方法的同步版本) 时, 将返回的WebClientAsyncResult实例。When you call the BeginMyMethodName method, where MyMethodName is the synchronous version of the method, on an XML Web service proxy class, an instance of the WebClientAsyncResult is returned. 按照标准异步设计模式, 稍后的实例WebClientAsyncResult必须传递到EndMyMethodName来完成异步方法调用。Following the standard asynchronous design pattern, that instance of WebClientAsyncResult must later be passed to EndMyMethodName to complete the asynchronous method call.

有关异步调用 XML Web services 的详细信息, 请参阅异步与 Xml Web services 进行通信For details on calling XML Web services asynchronously, see Communicating with XML Web Services Asynchronously.

属性

AsyncState

获取 Begin 方法异步调用的最后一个参数中提供的对象。Gets the object provided in the last parameter to the Begin method asynchronous call.

AsyncWaitHandle

获取用于等待异步操作完成的 WaitHandleGets a WaitHandle that is used to wait for an asynchronous operation to complete.

CompletedSynchronously

获取一个值,该值指示 Begin 调用是否已同步完成。Gets a value indicating whether the Begin call completed synchronously.

IsCompleted

获取一个值,该值指示异步 XML Web services 请求是否已完成。Gets a value indicating whether the asynchronous XML Web service request has completed.

方法

Abort()

取消异步 XML Web services 请求。Cancels an asynchronous XML Web service request.

Equals(Object)

确定指定的对象是否等于当前对象。Determines whether the specified object is equal to the current object.

(继承自 Object)
GetHashCode()

用作默认哈希函数。Serves as the default hash function.

(继承自 Object)
GetType()

获取当前实例的 TypeGets the Type of the current instance.

(继承自 Object)
MemberwiseClone()

创建当前 Object 的浅表副本。Creates a shallow copy of the current Object.

(继承自 Object)
ToString()

返回一个表示当前对象的 string。Returns a string that represents the current object.

(继承自 Object)

适用于

另请参阅