SodiumIsolateCallback<T> typedef

SodiumIsolateCallback<T> = FutureOr<T> Function(Sodium sodium, List<SecureKey> secureKeys, List<KeyPair> keyPairs)

A callback to be executed on a separate isolate.

The callback receives a fresh sodium instance that only lives on the new isolate, as well as the secureKeys and keyPairs that have been transferred to it via the Sodium.runIsolated method.

Implementation

typedef SodiumIsolateCallback<T> = FutureOr<T> Function(
  Sodium sodium,
  List<SecureKey> secureKeys,
  List<KeyPair> keyPairs,
);