Skip to main content

Module xfa

Module xfa 

Source
Expand description

XFA feature surface for pdf-engine.

This module is compiled only with the xfa feature and re-exports the high-level helpers needed to extract and flatten XFA content without making the base crate depend on the XFA stack by default.

Structs§

FormData
A JSON-friendly representation of an XFA form’s data.
FormNodeId
A unique identifier for a form node.
FormSchema
Schema metadata for a form’s fields.
FormTree
The form tree: a node-based representation of the merged template+data.
XfaFieldModel
SDK-level model of one fillable XFA form field, derived from the merged form tree and the current layout.
XfaFieldOption
A selectable option of a dropdown / list field.
XfaPackets
XfaPackets.
XfaRect
Axis-aligned rectangle in page space, points, top-left origin (XFA coordinate convention: y grows downward from the top of the page).
XfaSession
Parse-once session over a single XFA PDF.
XfaSetOutcome
Outcome of a successful XfaSession::set_value call.
XfaWidget
One layouted widget occurrence of a field.
XfaWritebackReport
Report from a save/writeback.

Enums§

XfaError
XfaError.
XfaFieldType
Public field type, mirroring FieldKind without leaking the layout-engine type into the SDK surface.
XfaWriteValue
A value to write into an XFA field.

Functions§

export_schema
Extract a schema from a FormTree.
extract_packets
Extract the XFA packets embedded in a document.
flatten
Flatten an XFA document into static PDF bytes.
flatten_with_password
Flatten an encrypted XFA document, using password to open it.
form_tree_to_json
Convert a FormTree into a JSON-friendly FormData structure.
form_tree_to_value
Convert a FormTree into a raw serde_json::Value.
has_xfa
Returns true if the document has an XFA template packet.