close method

  1. @override
Future<void> close()
override

Closes any opened file handles, removes temporary files, etc.

If the Fetcher is already closed then invoking this method has no effect.

Implementation

@override
Future<void> close() async {
  await Future.wait(_openedResources.mapNotNull((res) => res.close()));
  _openedResources.clear();
}