public PDFDocument(filename as String, maximumStreamSize as Int = 67108864)
Opens a PDF. Relative paths are resolved against the working directory.
| Parameter | Description |
|---|---|
filename | PDF filename. |
maximumStreamSize | Maximum decoded bytes per stream (64 MiB by default). |
try document = PDFDocument("report.pdf"):
print(document.pages.size)