computeFileListEncryptionPromiseWithPorts function

Future<ReceivePort> computeFileListEncryptionPromiseWithPorts(
  1. SendPort sendPort,
  2. FileListEncryptionPromise fileListEncryptionPromise
)

Implementation

Future<ReceivePort> computeFileListEncryptionPromiseWithPorts(
  SendPort sendPort,
  FileListEncryptionPromise fileListEncryptionPromise,
) async {
  ReceivePort receivePort = ReceivePort();

  await Isolate.spawn(
    executeFileListEncryptionPromise,
    [receivePort.sendPort, fileListEncryptionPromise.serialize()],
  );

  return receivePort;
}