pub struct NullRuntime { /* private fields */ }Expand description
Stub runtime that refuses every script call.
Implementations§
Source§impl NullRuntime
impl NullRuntime
Trait Implementations§
Source§impl Debug for NullRuntime
impl Debug for NullRuntime
Source§impl Default for NullRuntime
impl Default for NullRuntime
Source§fn default() -> NullRuntime
fn default() -> NullRuntime
Returns the “default value” for a type. Read more
Source§impl XfaJsRuntime for NullRuntime
impl XfaJsRuntime for NullRuntime
Source§fn reset_for_new_document(&mut self) -> Result<(), SandboxError>
fn reset_for_new_document(&mut self) -> Result<(), SandboxError>
Reset per-document state (memory budget, instruction counter,
any cached compiled scripts). Called once per flatten.
Source§fn execute_script(
&mut self,
_activity: Option<&str>,
_body: &str,
) -> Result<RuntimeOutcome, SandboxError>
fn execute_script( &mut self, _activity: Option<&str>, _body: &str, ) -> Result<RuntimeOutcome, SandboxError>
Execute one script body inside the sandbox. Read more
Source§fn take_metadata(&mut self) -> RuntimeMetadata
fn take_metadata(&mut self) -> RuntimeMetadata
Take the cumulative metadata since the last
take_metadata
call (or since reset_for_new_document, whichever was later).Source§fn set_form_handle(
&mut self,
_form: *mut FormTree,
_root_id: FormNodeId,
) -> Result<(), SandboxError>
fn set_form_handle( &mut self, _form: *mut FormTree, _root_id: FormNodeId, ) -> Result<(), SandboxError>
Phase C: install the
FormTree the runtime should resolve paths
against and mutate. The dispatch path owns the mutable borrow and clears
the handle before returning.Source§fn set_data_handle(&mut self, _dom: *const DataDom)
fn set_data_handle(&mut self, _dom: *const DataDom)
Phase D-γ: install a read-only view of the
DataDom for the current
document. Called once per document after set_form_handle, before any
scripts run. Default: no-op (backends without DataDom support ignore it). Read moreSource§fn reset_per_script(
&mut self,
_current_id: FormNodeId,
_activity: Option<&str>,
) -> Result<(), SandboxError>
fn reset_per_script( &mut self, _current_id: FormNodeId, _activity: Option<&str>, ) -> Result<(), SandboxError>
Phase C: reset per-script host counters and install the current script
context node / activity. Backends without host bindings ignore it.
Source§fn set_static_page_count(
&mut self,
_page_count: u32,
) -> Result<(), SandboxError>
fn set_static_page_count( &mut self, _page_count: u32, ) -> Result<(), SandboxError>
Phase C page-count foundation. The current flatten order runs scripts
before layout, so callers normally leave this at 0.
Auto Trait Implementations§
impl Freeze for NullRuntime
impl RefUnwindSafe for NullRuntime
impl Send for NullRuntime
impl Sync for NullRuntime
impl Unpin for NullRuntime
impl UnsafeUnpin for NullRuntime
impl UnwindSafe for NullRuntime
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
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 moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
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 moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
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().