createConnection method

FutureOr<C> createConnection()

Implementation

FutureOr<C> createConnection() async {
  var conn = await connectionInstantiator(credential,
      maxRetries: maxRetries, retryInterval: retryInterval);

  if (conn == null) {
    throw StateError("Can't create connection for $credential");
  }

  return conn;
}