close method

*[<Null safety>](https://dart.dev/null-safety)*
  • @override

void close ()

override

Implementation

@override
void close() {
  _isClosed = true;
  // schedule a task because if user closes this as soon as
  // they open a connection, dart fidl binding throws exception due to
  // event on this fidl.
  scheduleMicrotask(() {
    for (var c in _connections) {
      c.closeBinding();
    }
    _connections.clear();
  });
}