Begins to asynchronously receive data from a connected VirtualSocket.
[Visual Basic]
Overridable Public Function BeginReceive( _
ByVal buffer As Byte(), _
ByVal offset As Integer, _
ByVal size As Integer, _
ByVal socketFlags As SocketFlags, _
ByVal callback As AsyncCallback, _
ByVal state As Object _
) As IAsyncResult
An IAsyncResult that references the asynchronous read.
The BeginReceive method starts asynchronously reading data from a VirtualSocket. You must create a callback method that implements the AsyncCallback delegate. This callback method should use the EndReceive method to return the data read from the VirtualSocket.
Exception Type | Condition |
---|---|
ArgumentNullException | buffer is a null reference (Nothing in Visual Basic). |
SocketException | An operating system error occurs while accessing the VirtualSocket. |
ObjectDisposedException | VirtualSocket has been closed. |
ArgumentOutOfRangeException | offset is outside the bounds of buffer or size is either smaller or larger than the buffer size. |
VirtualSocket Class | VirtualSocket Members | Org.Mentalis.Security.Ssl Namespace