GetDocumentFeatureReport

Document properties, Content Extraction

Description

Produces a structured feature report of the selected document in one call, covering everything a cataloguing or ingest pipeline normally has to assemble from a dozen separate queries.

Syntax

Delphi

Function TPDFlib.GetDocumentFeatureReport: Integer;

Return values

0No document is selected.
IDA string list handle for GetStringListCount and GetStringListItem; release it with ReleaseStringList.

Remarks

Every line has the form Group,Key,Value. The groups are:

DocumentVersion, the standard metadata fields, page and object counts, linearisation and whether the cross-reference data had to be rebuilt.
SecurityEncryption state and level, and whether encryption is restricted to attachments.
FontsTotals for embedded, non-embedded, subsetted, standard-14, CID and Type 3 fonts, plus how many lack a Unicode mapping.
ImagesImage count summed across all pages.
StructureTagging state, structure element count and outline count.
InteractiveForm fields, signature fields and how many are signed, attachments and the portfolio view.
SpaceThe byte breakdown by category, forwarded from AuditDocumentSpace.

The report is a snapshot taken at call time. It reads the document without modifying it, and restores the selected page afterwards.

Example

ListID:= PDF.GetDocumentFeatureReport;
for I:= 1 to PDF.GetStringListCount(ListID) do
  Memo1.Lines.Add(PDF.GetStringListItem(ListID, I));
PDF.ReleaseStringList(ListID);

See also

AuditDocumentSpace, CheckDocumentStructure, GetDocumentFontDiagnostics, AnalyseFile