pub trait IntoScript {
// Required method
fn into_script(
self,
world: WorldAccessGuard<'_>,
) -> Result<ScriptValue, InteropError>;
// Provided method
fn into_script_inline_error(
self,
world: WorldAccessGuard<'_>,
) -> ScriptValue
where Self: Sized { ... }
}
Expand description
Converts a value into a ScriptValue
.
Required Methods§
Sourcefn into_script(
self,
world: WorldAccessGuard<'_>,
) -> Result<ScriptValue, InteropError>
fn into_script( self, world: WorldAccessGuard<'_>, ) -> Result<ScriptValue, InteropError>
Convert this value into a ScriptValue
.
Provided Methods§
Sourcefn into_script_inline_error(self, world: WorldAccessGuard<'_>) -> ScriptValuewhere
Self: Sized,
fn into_script_inline_error(self, world: WorldAccessGuard<'_>) -> ScriptValuewhere
Self: Sized,
Convert this value into a ScriptValue
, returning an error as a ScriptValue if an error occurs.