UdpAnySourceMulticastClient.EndReceiveFromGroup 方法

定义

注意

This API supports the .NET Framework infrastructure and is not intended to be used directly from your code.

完成从已联接的多播组接收数据包的异步操作并提供接收到的信息。

public:
 int EndReceiveFromGroup(IAsyncResult ^ result, [Runtime::InteropServices::Out] System::Net::IPEndPoint ^ % source);
[System.Obsolete("This API supports the .NET Framework infrastructure and is not intended to be used directly from your code.", true)]
public int EndReceiveFromGroup (IAsyncResult result, out System.Net.IPEndPoint source);
[<System.Obsolete("This API supports the .NET Framework infrastructure and is not intended to be used directly from your code.", true)>]
member this.EndReceiveFromGroup : IAsyncResult * IPEndPoint -> int
Public Function EndReceiveFromGroup (result As IAsyncResult, ByRef source As IPEndPoint) As Integer

参数

result
IAsyncResult

异步接收操作的结果。

source
IPEndPoint

从中接收数据包的源终结点。

返回

存储在传递给 BeginReceiveFromGroup(Byte[], Int32, Int32, AsyncCallback, Object) 方法的缓冲区参数中的消息长度(以字节为单位)。

属性

例外

result 为 null 引用(在 Visual Basic 中为 Nothing)。

尚未联接多播组。

尝试访问套接字时出错。

注解

方法 EndReceiveFromGroup 完成异步操作以接收来自多播组的数据包。

如果在执行接收操作时出现套接字故障, SocketException 则会引发 。 收到的错误指定为 枚举的成员 SocketError

适用于