This article was translated by machine. To view in the article in English, select the English check box. You can also display the English text in a popup window by moving the mouse pointer over the text.
This documentation is archived and is not being maintained.

LogicalMethodInfo.EndMethodInfo الخاصية

Visual Studio 2010

يحصل على السمات وبيانات التعريف Endأسلوب استدعاء غير متزامن إلى الأسلوب.

مساحة الاسم:  System.Web.Services.Protocols
التجميع:  System.Web.Services (في System.Web.Services.dll)

public MethodInfo EndMethodInfo { get; }

قيمة الخاصية

النوع: System.Reflection.MethodInfo
MethodInfo التي تمثل الالسمات و بيانات التعريف Endاستدعاء الأسلوب غير المتزامن.

using System;
using System.Reflection;
using System.Web.Services.Protocols;

public class MyService : SoapHttpClientProtocol
   public IAsyncResult BeginAdd(int xValue, int yValue,
                                AsyncCallback callback,
                                object asyncState)
      return this.BeginInvoke("Add", new object[] {xValue,yValue}, callback, asyncState);

   public int EndAdd(System.IAsyncResult asyncResult) 
      object[] results = this.EndInvoke(asyncResult);
      return ((int)(results[0]));

public class LogicalMethodInfo_Create
   public static void Main()
      Type myType = typeof(MyService);
      MethodInfo myBeginMethod = myType.GetMethod("BeginAdd");
      MethodInfo myEndMethod = myType.GetMethod("EndAdd");
      LogicalMethodInfo myLogicalMethodInfo = 
         (LogicalMethodInfo.Create(new MethodInfo[] { myBeginMethod,
                                                      myEndMethod },

      Console.WriteLine("\nThe asynchronous callback parameter of method {0} is :\n",
      Console.WriteLine("\t" + myLogicalMethodInfo.AsyncCallbackParameter.Name +
                              " : " + myLogicalMethodInfo.AsyncCallbackParameter.ParameterType);

            Console.WriteLine("\nThe asynchronous state parameter of method {0} is :\n",
      Console.WriteLine("\t" + myLogicalMethodInfo.AsyncStateParameter.Name +
         " : " + myLogicalMethodInfo.AsyncStateParameter.ParameterType);

      Console.WriteLine("\nThe asynchronous result parameter of method {0} is :\n",
      Console.WriteLine("\t" + myLogicalMethodInfo.AsyncResultParameter.Name +
         " : " + myLogicalMethodInfo.AsyncResultParameter.ParameterType);

      Console.WriteLine("\nThe begin method of the asynchronous method {0} is :\n",
      Console.WriteLine("\t" + myLogicalMethodInfo.BeginMethodInfo);

      Console.WriteLine("\nThe end method of the asynchronous method {0} is :\n",
      Console.WriteLine("\t" + myLogicalMethodInfo.EndMethodInfo);

         Console.WriteLine("\n{0} is asynchronous", myLogicalMethodInfo.Name);
         Console.WriteLine("\n{0} is synchronous", myLogicalMethodInfo.Name);


نظام التشغيل Windows 7, Windows Vista, Windows XP SP2, Windows XP Media Center Edition, الإصدار x64 من نظام التشغيل Windows XP Professional, Windows XP Starter Edition, Windows Server 2008, نظام التشغيل Windows Server 2003, نظام التشغيل Windows Server 2000 المزود بحزمة الخدمة SP4, نظام التشغيل Windows Millennium Edition, نظام التشغيل Windows 98

لا يدعم .NET Framework و .NET Compact Framework كافة الإصدارات الخاصة بكل نظام أساسي. للحصول على قائمة بالإصدارات المدعمة، راجع متطلبات النظام إطار عمل .NET.

.NET Framework

مدعوم في: 4, 3.5, 3.0, 2.0, 1.1, 1.0

NET Framework. Client Profile

مدعوم في: 4