Tell the clientInterface about a connection adapter.
773354
public ClientInterfaceHandleManager bindAdapter(final Connection adapter, final ClientInterfaceRepairCallback repairCallback) {
        return bindAdapter(adapter, repairCallback, false);
    }
39220
def get_sockinfo (host, port=None):
    """"""
    family, socktype = socket.AF_INET, socket.SOCK_STREAM
    return socket.getaddrinfo(host, port, family, socktype)
60707
async def prepare_conn(self, conn):
        """"""

        client_id = str(uuid.uuid4())
        monitor = functools.partial(self.send_event, client_id)

        self._logger.info("New client connection: %s", client_id)

        self.service_manager.add_monitor(monitor)

        self.clients[client_id] = dict(connection=conn, monitor=monitor)
        return client_id
315574
protected void printDead(String interfaceId, ProviderInfo providerInfo, ClientTransport transport, Exception e) {
        Throwable cause = e.getCause();
        if (LOGGER.isWarnEnabled(consumerConfig.getAppName())) {
            LOGGER.warnWithApp(consumerConfig.getAppName(),
                "Connect to {} provider:{} failure !! The exception is " + ExceptionUtils.toShortString(e, 1)
                    + (cause != null ? ", cause by " + cause.getMessage() + "." : "."),
                interfaceId, providerInfo);
        }
    }
944656
def get_client_sock(addr):
    ""
    s = _socket.create_connection(addr)
    s.setsockopt(_socket.SOL_SOCKET, _socket.SO_REUSEADDR, True)
    s.setblocking(False)
    return s
136272
function ApiclientAdapter(resource) {
    this.admin = admin;
    this.resource = resource || {};

    // loop through API interface for resource to get methods to expose
    var me = this;
    _.each(resource.api, function (methodInfo, httpMethod) {
        _.each(methodInfo, function (operation, path) {
            me[operation] = function (req) {
                return me.send(httpMethod, path, req);
            };
        });
    });
}
521331
def make_connector(self, app=None, bind=None):
        """"""
        return _EngineConnector(self, self.get_app(app), bind)
463540
public Connection getConnection(RpcClient rpcClient, ClientTransportConfig transportConfig, Url url) {
        if (rpcClient == null || transportConfig == null || url == null) {
            return null;
        }
        Connection connection;
        try {
            connection = rpcClient.getConnection(url, url.getConnectTimeout());
        } catch (InterruptedException e) {
            throw new SofaRpcRuntimeException(e);
        } catch (RemotingException e) {
            throw new SofaRpcRuntimeException(e);
        }
        if (connection == null) {
            return null;
        }

        return connection;
    }
1029689
def _on_disconnect(_loop, adapter, _adapter_id, conn_id):
    """"""

    conn_string = adapter._get_property(conn_id, 'connection_string')
    if conn_string is None:
        adapter._logger.debug("Dropping disconnect notification with unknown conn_id=%s", conn_id)
        return

    adapter._teardown_connection(conn_id, force=True)
    event = dict(reason='no reason passed from legacy adapter', expected=False)
    adapter.notify_event_nowait(conn_string, 'disconnection', event)
947226
def get_connection(self):
        """"""
        if self.host is None:
            connector = SpamCUnixConnector
            conn = connector(self.socket_file, self.backend_mod)
        else:
            connector = SpamCTcpConnector
            conn = connector(
                self.host,
                self.port,
                self.backend_mod,
                is_ssl=self.is_ssl,
                **self.ssl_args)
        return conn
474422
def _connect(self, sock, addr, timeout):
        """"""
        if self.connection:
            raise SocketClientConnectedError()

        if self.connector:
            raise SocketClientConnectingError()

        self.connect_deferred = Deferred(self.loop)
        self.sock = sock
        self.addr = addr
        self.connector = Connector(self.loop, sock, addr, timeout)
        self.connector.deferred.add_callback(self._connected)
        self.connector.deferred.add_errback(self._connect_failed)
        self.connector.start()

        return self.connect_deferred
1275864
def get_interfaces(self, socket_connection=None):
        """"""
        if not socket_connection:
            socket_connection = self.open_connection()
            close_socket = True
        else:
            close_socket = False

        # noinspection PyUnresolvedReferences
        _service = self.handler(self._interfaces["org.varlink.service"], socket_connection)
        self.info = _service.GetInfo()

        if close_socket:
            socket_connection.close()

        return self.info['interfaces']
193794
def clientConnectionFailed(self, connector, reason):
        
        print('. Reason:', reason)        
        ReconnectingClientFactory.clientConnectionFailed(self, connector, reason)
903506
protected void customizeConnection(String pathInContext, String pathParams, HttpRequest request, Socket socket) throws IOException
    {
    }
983666
def _get_interface_info(interface):
    '''
    
    '''
    adapter_mode = _get_adapter_mode_info(interface.name)
    if adapter_mode == 'disabled':
        return _get_base_interface_info(interface)
    elif adapter_mode == 'ethercat':
        return _get_ethercat_interface_info(interface)
    return _get_tcpip_interface_info(interface)
1199828
def connection(self):
        """"""
        self.getPorts()         # acquire if necessary
        self.getIPaddresses()   # acquire if necessary
        return (self.ipAddress, self.ports)
38956
function Adapter(clientPtcl, serverPtcl, fingerprint) {
  this._clientPtcl = clientPtcl;
  this._serverPtcl = serverPtcl;
  this._fingerprint = fingerprint; // Convenience.
  this._rsvs = clientPtcl.equals(serverPtcl) ? null : this._createResolvers();
}