close method

Future close ()

Closes all registered resources.

Invokes the closing method for each object that has been registered.

Implementation

Future close() async {
  await Future.wait(_registrations.map((r) => r.close()));
  _registrations = [];
}