Skip to main content

RuntimeMetadata

Struct RuntimeMetadata 

Source
pub struct RuntimeMetadata {
Show 38 fields pub executed: usize, pub runtime_errors: usize, pub timeouts: usize, pub oom: usize, pub host_calls: usize, pub mutations: usize, pub instance_writes: usize, pub list_writes: usize, pub binding_errors: usize, pub resolve_failures: usize, pub data_reads: usize, pub unsupported_host_calls: usize, pub probe_skips: usize, pub variables_scripts_collected: usize, pub variables_data_items_collected: usize, pub script_objects_registered: usize, pub script_objects_register_failed: usize, pub script_objects_subform_scoped: usize, pub som_lookups_total: usize, pub som_lookup_successes: usize, pub som_lookup_failures: usize, pub som_lookup_ambiguous: usize, pub som_subform_scripts_exposed: usize, pub som_occur_path_refs: usize, pub occur_lookups_total: usize, pub occur_lookup_successes: usize, pub occur_lookup_failures: usize, pub occur_property_reads: usize, pub occur_property_writes: usize, pub occur_min_writes: usize, pub occur_max_writes: usize, pub occur_mutations_captured: usize, pub occur_mutations_applied: usize, pub occur_mutations_skipped: usize, pub occur_application_ambiguous: usize, pub occur_application_targets: usize, pub som_data_root_hits: usize, pub som_items_path_hits: usize,
}
Expand description

Cumulative metadata for a single document’s flatten. The runtime adapter accumulates counters across calls; the dispatch site reads them via XfaJsRuntime::take_metadata when the document is done.

Fields§

§executed: usize

Scripts that ran to completion inside the sandbox.

§runtime_errors: usize

Generic runtime / script errors (parse, throw, NoBindings, …).

§timeouts: usize

Time-budget exhaustions.

§oom: usize

Memory-budget exhaustions.

§host_calls: usize

Phase C host-binding invocations.

§mutations: usize

Phase C successful field.rawValue writes.

§instance_writes: usize

Phase D successful instanceManager structure writes.

§list_writes: usize

Phase D-β successful listbox clearItems / addItem writes.

§binding_errors: usize

Phase C binding-level failures (type, activity, cap, parse).

§resolve_failures: usize

Phase C SOM resolution misses / failures.

§data_reads: usize

Phase D-γ successful DataDom reads (children / value / child-by-name).

§unsupported_host_calls: usize

Phase E (XFA-JS-HOST-STUBS): Calls into host capabilities that require genuine viewer / user interaction (UI dialogs, signature panels, network submit). The sandbox cannot honestly satisfy these during a non-interactive flatten; instead of raising a TypeError (which would abort the script and inflate runtime_errors) the stubs return a safe default value and increment this counter so the dispatch site keeps observability of “would-have-been-interactive” touch points. Note: this counter is intentionally NOT folded into is_clean — a script that touched xfa.host.messageBox is still considered to have run cleanly because the sandbox did not error; embedders that care about UI gaps should inspect this field explicitly.

§probe_skips: usize

Phase D-θ.2 probe calls skipped because parentIds.length == 1 && chain.length == 1 (no same-name ambiguity possible). Every skipped call saves one resolveWithFullChainStrict host round-trip.

§variables_scripts_collected: usize

D3 (trace-only): <variables> <script> objects collected from the template for this document (root + subform scopes).

§variables_data_items_collected: usize

D3 (trace-only): <variables> <text> data items collected.

§script_objects_registered: usize

D3 (trace-only): script objects whose JS-side registration returned success (namespace bound into variablesScripts / subformVariables).

§script_objects_register_failed: usize

D3 (trace-only): script objects that did NOT register — either a Rust skip (BodyTooLarge / RegexRejected / panic) or a JS-side eval failure (setVariablesScript returned false). Pure observability; never folded into is_clean or rollback.

§script_objects_subform_scoped: usize

D3 (trace-only): script objects collected under a NESTED subform scope (registered into subformVariables only, hence not reachable as a bare identifier today — the “scope_hidden” gap class).

§som_lookups_total: usize

D4: total SOM lookups observed at the host resolve boundary (successes + failures across the instrumented resolve_* entry points).

§som_lookup_successes: usize

D4: SOM lookups that resolved to at least one node.

§som_lookup_failures: usize

D4: SOM lookups that returned NoMatch.

§som_lookup_ambiguous: usize

D4: subform-scoped script-object names NOT exposed because the same name is declared by ≥2 subforms (fail-closed ambiguity).

§som_subform_scripts_exposed: usize

D4: subform-scoped script objects exposed to bare-identifier lookup (unique-name, sandboxed-only).

§som_occur_path_refs: usize

D4 (trace-only): SOM NoMatch references whose path is an occur path (occur / occur.min / occur.max …). Classified, NOT resolved.

§occur_lookups_total: usize

D5: node.occur handle accesses (successes + failures).

§occur_lookup_successes: usize

D5: node.occur accesses where the node handle was live.

§occur_lookup_failures: usize

D5: node.occur accesses where the node handle was not live.

§occur_property_reads: usize

D5: reads of an occur property (min/max/initial).

§occur_property_writes: usize

D5: writes to an occur property (captured, not applied).

§occur_min_writes: usize

D5: writes specifically to occur.min.

§occur_max_writes: usize

D5: writes specifically to occur.max.

§occur_mutations_captured: usize

D5: occur mutations captured as intent (no layout effect).

§occur_mutations_applied: usize

D5: occur mutations APPLIED to layout. Always 0 in D5 (capture-only); D6 bumps this when XFA_OCCUR_APPLY=1 applies a captured occur.min.

§occur_mutations_skipped: usize

D6: captured occur mutations NOT applied (rollback, apply-flag off, dead/non-repeatable target, unsupported prop, negative value).

§occur_application_ambiguous: usize

D6: captured occur mutations skipped because the target node is not a repeatable container (Subform/Area/ExclGroup) — fail-closed.

§occur_application_targets: usize

D6: distinct form nodes whose occur was applied.

§som_data_root_hits: usize

BE-1: $data bare-global intercepts resolved successfully (JS layer).

§som_items_path_hits: usize

BE-1: #items property accesses resolved to a non-empty item list.

Implementations§

Source§

impl RuntimeMetadata

Source

pub fn is_clean(&self) -> bool

True when the runtime never reported any error class.

Source

pub fn accumulate(&mut self, other: RuntimeMetadata)

Add another metadata snapshot into this one.

Trait Implementations§

Source§

impl Clone for RuntimeMetadata

Source§

fn clone(&self) -> RuntimeMetadata

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Copy for RuntimeMetadata

Source§

impl Debug for RuntimeMetadata

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for RuntimeMetadata

Source§

fn default() -> RuntimeMetadata

Returns the “default value” for a type. Read more
Source§

impl Eq for RuntimeMetadata

Source§

impl PartialEq for RuntimeMetadata

Source§

fn eq(&self, other: &RuntimeMetadata) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl StructuralPartialEq for RuntimeMetadata

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
Source§

impl<T> ErasedDestructor for T
where T: 'static,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

impl<T> ParallelSend for T

Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<R, P> ReadPrimitive<R> for P
where R: Read + ReadEndian<P>, P: Default,

Source§

fn read_from_little_endian(read: &mut R) -> Result<Self, Error>

Read this value from the supplied reader. Same as ReadEndian::read_from_little_endian().
Source§

fn read_from_big_endian(read: &mut R) -> Result<Self, Error>

Read this value from the supplied reader. Same as ReadEndian::read_from_big_endian().
Source§

fn read_from_native_endian(read: &mut R) -> Result<Self, Error>

Read this value from the supplied reader. Same as ReadEndian::read_from_native_endian().
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, S> SimdFrom<T, S> for T
where S: Simd,

Source§

fn simd_from(value: T, _simd: S) -> T

Source§

impl<F, T, S> SimdInto<T, S> for F
where T: SimdFrom<F, S>, S: Simd,

Source§

fn simd_into(self, simd: S) -> T

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V