Starts an asynchronously request to listen for an incoming connection using the specified control socket as a base.
Namespace:
Rebex.Net
Assembly:
Rebex.Networking (in Rebex.Networking.dll)
Syntax
Visual Basic |
---|
Public Function BeginListen ( _ controlSocket As ISocket, _ callback As AsyncCallback, _ state As Object _ ) As IAsyncResult |
C# |
---|
public IAsyncResult BeginListen( ISocket controlSocket, AsyncCallback callback, Object state ) |
Parameters
- controlSocket
- Type: Rebex.Net..::..ISocket
The control socket to use as a base.
- callback
- Type: System..::..AsyncCallback
The AsyncCallback delegate.
- state
- Type: System..::..Object
An object containing state information for this request.
Return Value
An IAsyncResult that references the asynchronous request.Implements
ISocketExt..::..BeginListen(ISocket, AsyncCallback, Object)
Remarks
This method differs from Listen(Int32):
- A control connection socket needs to be specified. This might be needed by a proxy server socket.
- Only a single incoming connection is accepted.
Note: When connected through a HTTP proxy server, this method will fail.