Ice::Connection

Overview

local interface Connection

The user-level interface to a connection.

Used By

Current::con

Operation Index

close

Close a connection, either gracefully or forcefully.

createProxy

Create a proxy that always uses this connection.

flushBatchRequests

Flush any pending batch requests for this connection.

timeout

Get the timeout for the connection.

toString

Return a description of the connection as human readable text, suitable for logging or error messages.

type

Return the connection type.

close

void close(bool force);

Close a connection, either gracefully or forcefully. If a connection is closed forcefully, it closes immediately, without sending the relevant close connection protocol messages to the peer and waiting for the peer to acknowledge these protocol messages.

Parameters

force

If true, close forcefully. Otherwise the connection is closed gracefully.

createProxy

Object* createProxy(Identity id);

Create a proxy that always uses this connection. This is typically used for reverse communications using connections that have been established from a client to an object adapter.

Note

This operation is intended to be used by special services, such as Router implementations. Regular user code should not attempt to use this operation.

Parameters

id

The identity for which a proxy is to be created.

Return Value

A proxy that matches the given identity and uses this connection.

See Also

Identity

flushBatchRequests

void flushBatchRequests();

Flush any pending batch requests for this connection. This causes all batch requests that were sent via proxies that use this connection to be sent to the server.

timeout

int timeout();

Get the timeout for the connection.

Return Value

The connection's timeout.

toString

string toString();

Return a description of the connection as human readable text, suitable for logging or error messages.

Return Value

The description of the connection as human readable text.

type

string type();

Return the connection type. This corresponds to the endpoint type, i.e., "tcp", "udp", etc.

Return Value

The type of the connection.