close method Null safety

Future<void> close()

Implementation

Future<void> close() async {
  if (!_isOpen) {
    return;
  }
  flush();
  _isOpen = false;
  await _fp.close();
}