close method

Future<void> close()

After you finish working with the document, you should close it to avoid memory leak.

Implementation

Future<void> close() => _lock.synchronized(() async {
      if (isClosed) {
        throw PdfDocumentAlreadyClosedException();
      } else {
        isClosed = true;
      }
      return _channel.invokeMethod('close.document', id);
    });