SmartSockets .NET Class Library

TipcSvc.createConnServer Method 

Create a new peer-to-peer server connection.

This method creates the server end of a peer-to-peer connection. The protocol, hostname, and port number are specified using the same "logical connection name" (LCN) as the client connection.

This connection is only used to accept connections from clients. All actual communication is done with the client connection returned by accept.

Example:

            // create the server-side of a connection listening via TCP on port 8002
            TipcConnServer srvConn = TipcSvc.createConnServer("tcp:_node:8002");
            
            // accept a client connection
            TipcConnClient conn = srvConn.accept();
            
            // get the next message sent by the client
            TipcMsg msg = conn.next(10.0);
            

public static TipcConnServer createConnServer(
   string lcn
);

Parameters

lcn
the logical connection name to use for the connection

Return Value

the new connection interface

Exceptions

Exception TypeCondition
TipcBadArgumentException If the LCN is invalid
TipcAssertionException If the LCN hostname is unknown
TipcIOException For lower-level errors
TipcException For all other errors

See Also

TipcSvc Class | TipcSvc Members | TIBCO.SMARTSOCKETS Namespace | TipcConnServer | TipcConnClient


Copyright © TIBCO Software Inc. All rights reserved