ensureConnection method

FlowControlledRemoteConnection<T> ensureConnection()
inherited

Ensures connection is established for remote interactions

Implementation

FlowControlledRemoteConnection<T> ensureConnection() {
  final existing = remoteConnection;
  if (existing != null) return existing;

  final newConn = FlowControlledRemoteConnection<T>.forSender(remotePort);
  _senderConnections[this] = newConn;
  _cachedConn = newConn;
  return newConn;
}