SocketExtensionsAcceptAsync(Socket, Socket, Int32) Method

Asynchronously waits to accept an incoming connection.

Definition

Namespace: DevCase.Extensions.SocketExtensions
Assembly: DevCase.net48 (in DevCase.net48.dll) Version: 6.0.0.0 (6.0)
XMLNS for XAML: Not mapped to an xmlns.
[EditorBrowsableAttribute(EditorBrowsableState.Always)]
public static Task<Socket> AcceptAsync(
	this Socket s,
	Socket acceptSocket,
	int receiveSize
)

Parameters

s  Socket

[Missing <param name="s"/> documentation for "M:DevCase.Extensions.SocketExtensions.SocketExtensions.AcceptAsync(System.Net.Sockets.Socket,System.Net.Sockets.Socket,System.Int32)"]

acceptSocket  Socket
The accepted Socket object.

This value can be null.

receiveSize  Int32
The number of bytes to accept from the sender.

Return Value

TaskSocket
The resulting TaskTResult.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type Socket. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).

See Also