Mentalis.org Security Library documentation

SecureNetworkStream.BeginWrite Method 

Begins an asynchronous write to a stream.

[Visual Basic]
Overrides Public Function BeginWrite( _
   ByVal buffer As Byte(), _
   ByVal offset As Integer, _
   ByVal size As Integer, _
   ByVal callback As AsyncCallback, _
   ByVal state As Object _
) As IAsyncResult
[C#]
public override IAsyncResult BeginWrite(
   byte[] buffer,
   int offset,
   int size,
   AsyncCallback callback,
   object state
);

Parameters

buffer
The location in memory that holds the data to send.
offset
The location in buffer to begin sending the data.
size
The size of buffer.
callback
The delegate to call when the asynchronous call is complete.
state
An object containing additional information supplied by the client.

Return Value

An IAsyncResult representing the asynchronous call.

Exceptions

Exception TypeCondition
ArgumentNullExceptionbuffer is a null reference (Nothing in Visual Basic).
ArgumentOutOfRangeExceptionThe specified offset or size exceeds the size of buffer.
IOExceptionThere is a failure while writing to the network.

See Also

SecureNetworkStream Class | SecureNetworkStream Members | Org.Mentalis.Security.Ssl Namespace