getAll method

Stream<PDFPage?> getAll({
  1. dynamic onZoomChanged(
    1. double
    )?,
})

Implementation

Stream<PDFPage?> getAll({final Function(double)? onZoomChanged}) {
  return Future.forEach<PDFPage?>(List.filled(count, null), (i) async {
    final data = await _channel
        .invokeMethod('getPage', {'filePath': _filePath, 'pageNumber': i});
    return PDFPage(
      data as String?,
      1,
      onZoomChanged: onZoomChanged,
    );
  }).asStream() as Stream<PDFPage?>;
}