PdfPageText class final

The result of plain text extraction for a single PDF page.

Produced by PdfDocument.extractPlainText. Each item in the stream corresponds to one page.

hasTextLayer is the primary signal for whether useful text was extracted. Use PdfDocument.isPlainTextExtractable when you need a document-level heuristic rather than per-page signals.

Constructors

PdfPageText({required int pageIndex, required String text, required bool hasUnicodeErrors, required bool hasTextLayer})
Creates an immutable PdfPageText value.
const

Properties

hashCode int
The hash code for this object.
no setteroverride
hasTextLayer bool
True when PDFium extracted at least one character from this page.
final
hasUnicodeErrors bool
True when at least one character on this page had a broken Unicode mapping (i.e. FPDFText_HasUnicodeMapError returned non-zero for it).
final
pageIndex int
Zero-based index of the page this result corresponds to.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
text String
The extracted Unicode text for this page.
final

Methods

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