PdfDocument class abstract

Handles PDF document loaded on memory.

Constructors

PdfDocument({required String sourceName, required int pageCount, required int verMajor, required int verMinor, required bool isEncrypted, required bool allowsCopying, required bool allowsPrinting})

Properties

allowsCopying → bool
Determine whether the PDF file allows copying of the contents.
final
allowsPrinting → bool
Determine whether the PDF file allows printing of the pages.
final
hashCode → int
The hash code for this object.
no setteroverride
isEncrypted → bool
Determine whether the PDF file is encrypted or not.
final
pageCount → int
Number of pages in the PDF document.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
sourceName → String
File path, asset:[ASSET_PATH] or memory: depending on the content opened.
final
verMajor → int
PDF major version.
final
verMinor → int
PDF minor version.
final

Methods

dispose() → Future<void>
getPage(int pageNumber) → Future<PdfPage>
Get page object. The first page is 1.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
override

Operators

operator ==(dynamic other) → bool
The equality operator.
override

Static Methods

openAsset(String name) → Future<PdfDocument>
Opening the specified asset.
openData(Uint8List data) → Future<PdfDocument>
Opening the PDF on memory.
openFile(String filePath) → Future<PdfDocument>
Opening the specified file. For Web, filePath can be relative path from index.html or any arbitrary URL but it may be restricted by CORS.