PdfPasswordProvider typedef

PdfPasswordProvider = FutureOr<String?> Function()

Function to provide password for encrypted PDF.

The function is called when PDF requires password. It is repeatedly called until the function returns null or the password is correct.

createOneTimePasswordProvider is a helper function to create PdfPasswordProvider that returns the password only once.

Implementation

typedef PdfPasswordProvider = FutureOr<String?> Function();