Click or drag to resize

ConnectionOpen Method (OpenFlags)

Opens (or reopens) the socket.

Namespace:  Demo3D.Net
Assembly:  Demo3D.IO (in Demo3D.IO.dll) Version: 15.0.2.11458
Syntax
C#
public void Open(
	OpenFlags openFlags = OpenFlags.Default
)

Parameters

openFlags (Optional)
Type: Demo3D.NetOpenFlags
Additional flags.
Examples
C#
public Client<IPacketIOService> OpenClient(string host, int port) {
    // Create a connection to a client, without opening it.
    var client = TcpClient.Open(host, port, OpenFlags.NoOpen);

    // Get the protocol properties and set TCP.ReceiveTimeout to 1 second.
    dynamic properties            = client.Properties;
    properties.TCP.ReceiveTimeout = 1000;

    // Open the connection.
    client.Open();

    return client;
}
See Also