read method
Reads encoded image bytes for key.
Implementation
@override
Future<Uint8List?> read(CPDFPageThumbnailKey key) async {
final file = await _fileForKey(key);
if (!await file.exists()) {
return null;
}
if (_isExpired(file, key)) {
await file.delete();
return null;
}
return file.readAsBytes();
}