PdfDocument class abstract
PDF page image renderer
Constructors
- PdfDocument({required String sourceName, required String id, required int pagesCount})
Properties
- hashCode → int
-
The hash code for this object.
no setteroverride
- id → String
-
Document unique id.
Generated when opening document.
final
- isClosed ↔ bool
-
Is the document closed
getter/setter pair
- pagesCount → int
-
All pages count in document.
Starts from 1.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- sourceName → String
-
Needed for toString method
Contains a method for opening a document (file, data or asset)
final
Methods
-
close(
) → Future< void> -
getPage(
int pageNumber, {bool autoCloseAndroid = false}) → 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 ==(
Object other) → bool -
The equality operator.
override
Static Methods
-
openAsset(
String name, {String? password}) → Future< PdfDocument> -
Opening the specified asset.
password supported only for web!
-
openData(
FutureOr< Uint8List> data, {String? password}) → Future<PdfDocument> -
Opening the PDF on memory.
password supported only for web!
-
openFile(
String filePath, {String? password}) → Future< PdfDocument> -
Opening the specified file.
For Web,
filePath
can be relative path fromindex.html
or any arbitrary URL but it may be restricted by CORS.password supported only for web!