THPDFQuickJS.InstallAliasMapOptimization

Unit: HPDFQuickJS

Declaration

function InstallAliasMapOptimization: Boolean;

Installs the native initialization helper used by the XFA alias bootstrap and returns True on success. Returns False when the engine is unavailable, the optional export is missing, the engine is busy or installation cannot complete within its resources

Check SupportsAliasMapOptimization when distinguishing older providers from an installation failure. Existing TXFAJavaScriptSession instances perform installation automatically during engine creation and reconstruction; applications using that class need no additional call

Call this method only at engine initialization, before installing the XFA support bootstrap and before user evaluation. It publishes a reserved temporary __hpdfAliasMapNative function with an own data capability; the bootstrap captures and removes that global and enables only its freshly created empty genuine alias Map

The installer itself performs no user JavaScript or key coercion. A caller-supplied preexisting XFA state, nonempty Map or replacement map-like object retains its normal representation and behavior. Ordinary newly constructed Maps remain on the generic native path

All backing allocations use the existing VM budget. Arbitrary keys or values, excessive fragmentation and internal representation boundaries trigger atomic promotion to ordinary native Map storage; promotion can fail if that representation does not fit. A failed representation transition leaves the previous Map contents and iterator positions intact

See also

Runtime build and deployment and Session alias storage