pub struct AddScriptToEvaluateOnNewDocumentParams {
pub source: String,
pub worldName: Option<String>,
pub includeCommandLineAPI: Option<bool>,
pub runImmediately: Option<bool>,
}Expand description
Evaluates given script in every frame upon creation (before loading frame’s scripts).
Fields§
§source: String§worldName: Option<String>If specified, creates an isolated world with the given name and evaluates given script in it. This world name will be used as the ExecutionContextDescription::name when the corresponding event is emitted.
includeCommandLineAPI: Option<bool>Specifies whether command line API should be available to the script, defaults to false.
runImmediately: Option<bool>If true, runs the script immediately on existing execution contexts or worlds. Default: false.
Trait Implementations§
Source§impl Clone for AddScriptToEvaluateOnNewDocumentParams
impl Clone for AddScriptToEvaluateOnNewDocumentParams
Source§fn clone(&self) -> AddScriptToEvaluateOnNewDocumentParams
fn clone(&self) -> AddScriptToEvaluateOnNewDocumentParams
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Default for AddScriptToEvaluateOnNewDocumentParams
impl Default for AddScriptToEvaluateOnNewDocumentParams
Source§fn default() -> AddScriptToEvaluateOnNewDocumentParams
fn default() -> AddScriptToEvaluateOnNewDocumentParams
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for AddScriptToEvaluateOnNewDocumentParams
impl<'de> Deserialize<'de> for AddScriptToEvaluateOnNewDocumentParams
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for AddScriptToEvaluateOnNewDocumentParams
impl RefUnwindSafe for AddScriptToEvaluateOnNewDocumentParams
impl Send for AddScriptToEvaluateOnNewDocumentParams
impl Sync for AddScriptToEvaluateOnNewDocumentParams
impl Unpin for AddScriptToEvaluateOnNewDocumentParams
impl UnsafeUnpin for AddScriptToEvaluateOnNewDocumentParams
impl UnwindSafe for AddScriptToEvaluateOnNewDocumentParams
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