pub struct CallFunctionOnBuilder { /* private fields */ }Expand description
Builder for CallFunctionOn.
Implementations§
Source§impl CallFunctionOnBuilder
impl CallFunctionOnBuilder
Sourcepub fn function_declaration<VALUE: Into<String>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn function_declaration<VALUE: Into<String>>( &mut self, value: VALUE, ) -> &mut Self
Declaration of the function to call.
Sourcepub fn object_id<VALUE: Into<RemoteObjectId>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn object_id<VALUE: Into<RemoteObjectId>>( &mut self, value: VALUE, ) -> &mut Self
Identifier of the object to call function on. Either objectId or executionContextId should be specified.
Sourcepub fn arguments<VALUE: Into<Vec<CallArgument>>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn arguments<VALUE: Into<Vec<CallArgument>>>( &mut self, value: VALUE, ) -> &mut Self
Call arguments. All call arguments must belong to the same JavaScript world as the target object.
Sourcepub fn silent<VALUE: Into<bool>>(&mut self, value: VALUE) -> &mut Self
pub fn silent<VALUE: Into<bool>>(&mut self, value: VALUE) -> &mut Self
In silent mode exceptions thrown during evaluation are not reported and do not pause
execution. Overrides setPauseOnException state.
Sourcepub fn return_by_value<VALUE: Into<bool>>(&mut self, value: VALUE) -> &mut Self
pub fn return_by_value<VALUE: Into<bool>>(&mut self, value: VALUE) -> &mut Self
Whether the result is expected to be a JSON object which should be sent by value.
Can be overriden by serializationOptions.
Sourcepub fn generate_preview<VALUE: Into<bool>>(&mut self, value: VALUE) -> &mut Self
pub fn generate_preview<VALUE: Into<bool>>(&mut self, value: VALUE) -> &mut Self
Whether preview should be generated for the result.
Sourcepub fn user_gesture<VALUE: Into<bool>>(&mut self, value: VALUE) -> &mut Self
pub fn user_gesture<VALUE: Into<bool>>(&mut self, value: VALUE) -> &mut Self
Whether execution should be treated as initiated by user in the UI.
Sourcepub fn await_promise<VALUE: Into<bool>>(&mut self, value: VALUE) -> &mut Self
pub fn await_promise<VALUE: Into<bool>>(&mut self, value: VALUE) -> &mut Self
Whether execution should await for resulting value and return once awaited promise is
resolved.
Sourcepub fn execution_context_id<VALUE: Into<ExecutionContextId>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn execution_context_id<VALUE: Into<ExecutionContextId>>( &mut self, value: VALUE, ) -> &mut Self
Specifies execution context which global object will be used to call function on. Either executionContextId or objectId should be specified.
Sourcepub fn object_group<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
pub fn object_group<VALUE: Into<String>>(&mut self, value: VALUE) -> &mut Self
Symbolic group name that can be used to release multiple objects. If objectGroup is not specified and objectId is, objectGroup will be inherited from object.
Sourcepub fn throw_on_side_effect<VALUE: Into<bool>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn throw_on_side_effect<VALUE: Into<bool>>( &mut self, value: VALUE, ) -> &mut Self
Whether to throw an exception if side effect cannot be ruled out during evaluation.
Sourcepub fn unique_context_id<VALUE: Into<String>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn unique_context_id<VALUE: Into<String>>( &mut self, value: VALUE, ) -> &mut Self
An alternative way to specify the execution context to call function on.
Compared to contextId that may be reused across processes, this is guaranteed to be
system-unique, so it can be used to prevent accidental function call
in context different than intended (e.g. as a result of navigation across process
boundaries).
This is mutually exclusive with executionContextId.
Sourcepub fn serialization_options<VALUE: Into<SerializationOptions>>(
&mut self,
value: VALUE,
) -> &mut Self
pub fn serialization_options<VALUE: Into<SerializationOptions>>( &mut self, value: VALUE, ) -> &mut Self
Specifies the result serialization. If provided, overrides
generatePreview and returnByValue.
Sourcepub fn build(&self) -> Result<CallFunctionOn, CallFunctionOnBuilderError>
pub fn build(&self) -> Result<CallFunctionOn, CallFunctionOnBuilderError>
Trait Implementations§
Source§impl Clone for CallFunctionOnBuilder
impl Clone for CallFunctionOnBuilder
Source§fn clone(&self) -> CallFunctionOnBuilder
fn clone(&self) -> CallFunctionOnBuilder
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more