toMap method

Map<String, dynamic> toMap()

Converts the options to a map that can be passed to the platform channel.

Implementation

Map<String, dynamic> toMap() {
  return <String, dynamic>{
    'userPassword': userPassword,
    'ownerPassword': ownerPassword,
    'flatten': flatten,
    'incremental': incremental,
    'permissions': permissions?.map((e) => e.name).toList(),
    'pdfVersion': pdfVersion?.name,
  }..removeWhere((key, value) => value == null);
}