C-DEngine 5.105

WebSocketSessionManager..::..SendToAsync Method (Stream, Int32, String, Action<(Of <(<'Boolean>)>)>)

Sends binary data from the specified Stream asynchronously to the client on the session with the specified id.

Namespace:  WebSocketSharp.Server
Assembly:  C-DEngine (in C-DEngine.dll)

Syntax


public void SendToAsync(
	Stream stream,
	int length,
	string id,
	Action<bool> completed
)
Public Sub SendToAsync ( _
	stream As Stream, _
	length As Integer, _
	id As String, _
	completed As Action(Of Boolean) _
)
public:
void SendToAsync(
	Stream^ stream, 
	int^ length, 
	String^ id, 
	Action<bool^>^ completed
)

Parameters

stream
Type: Stream
A Stream from which contains the binary data to send.
length
Type: Int32
An Int32 that represents the number of bytes to send.
id
Type: String
A String that represents the ID of the session to find.
completed
Type: Action<(Of <(<'Boolean>)>)>
An Action<bool> delegate that references the method(s) called when the send is complete. A Boolean passed to this delegate is true if the send is complete successfully.

Remarks


This method doesn't wait for the send to be complete.