Mentalis.org Security Library documentation

SecureSocket.Send Method (Byte[], Int32, SocketFlags)

Sends data to a connected SecureSocket, starting at the indicated location in the data.

[Visual Basic]
Overrides Overloads Public Function Send( _
   ByVal buffer As Byte(), _
   ByVal size As Integer, _
   ByVal socketFlags As SocketFlags _
) As Integer
[C#]
public override int Send(
   byte[] buffer,
   int size,
   SocketFlags socketFlags
);

Parameters

buffer
The data to be sent.
size
The number of bytes to send.
socketFlags
A bitwise combination of the SocketFlags values.

Return Value

The number of bytes sent to the SecureSocket.

Exceptions

Exception TypeCondition
ArgumentNullExceptionbuffer is a null reference (Nothing in Visual Basic).
SocketExceptionAn operating system error occurs while accessing the SecureSocket.
ArgumentOutOfRangeExceptionThe size parameter exceeds the size of buffer.
ObjectDisposedExceptionThe SecureSocket has been closed.
SecurityExceptionUnable to encrypt the data.

See Also

SecureSocket Class | Org.Mentalis.Security.Ssl Namespace | SecureSocket.Send Overload List