pub struct AddScriptToEvaluateOnNewDocumentBuilder { /* private fields */ }Expand description
Builder for AddScriptToEvaluateOnNewDocument.
Implementations§
Source§impl AddScriptToEvaluateOnNewDocumentBuilder
impl AddScriptToEvaluateOnNewDocumentBuilder
pub fn source<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
Sourcepub fn world_name<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn world_name<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
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.
Sourcepub fn include_command_line_api<VALUE: Into<bool>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn include_command_line_api<VALUE: Into<bool>>( &mut self, value: VALUE, ) -> &mut Self
Specifies whether command line API should be available to the script, defaults to false.
Sourcepub fn run_immediately<VALUE: Into<bool>>(&mut self, value: VALUE) -> &mut Self
pub fn run_immediately<VALUE: Into<bool>>(&mut self, value: VALUE) -> &mut Self
If true, runs the script immediately on existing execution contexts or worlds. Default: false.
Sourcepub fn build(
&self,
) -> Result<AddScriptToEvaluateOnNewDocument, AddScriptToEvaluateOnNewDocumentBuilderError>
pub fn build( &self, ) -> Result<AddScriptToEvaluateOnNewDocument, AddScriptToEvaluateOnNewDocumentBuilderError>
Builds a new AddScriptToEvaluateOnNewDocument.
§Errors
If a required field has not been initialized.
Trait Implementations§
Source§impl Clone for AddScriptToEvaluateOnNewDocumentBuilder
impl Clone for AddScriptToEvaluateOnNewDocumentBuilder
Source§fn clone(&self) -> AddScriptToEvaluateOnNewDocumentBuilder
fn clone(&self) -> AddScriptToEvaluateOnNewDocumentBuilder
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 moreAuto Trait Implementations§
impl Freeze for AddScriptToEvaluateOnNewDocumentBuilder
impl RefUnwindSafe for AddScriptToEvaluateOnNewDocumentBuilder
impl Send for AddScriptToEvaluateOnNewDocumentBuilder
impl Sync for AddScriptToEvaluateOnNewDocumentBuilder
impl Unpin for AddScriptToEvaluateOnNewDocumentBuilder
impl UnsafeUnpin for AddScriptToEvaluateOnNewDocumentBuilder
impl UnwindSafe for AddScriptToEvaluateOnNewDocumentBuilder
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