Struct neon::types::function::CallOptions[][src]

pub struct CallOptions<'a> { /* fields omitted */ }
Expand description

A builder for making a JavaScript function call like parseInt("42").

The builder methods make it convenient to assemble the call from parts:

let x: Handle<JsNumber> = parse_int
    .call_with(&cx)
    .arg(cx.string("42"))
    .apply(&mut cx)?;

Implementations

Set the value of this for the function call.

Add an argument to the arguments list.

Replaces the arguments list with the given arguments.

Make the function call. If the function returns without throwing, the result value is downcast to the type V, throwing a TypeError if the downcast fails.

Make the function call for side effect, discarding the result value. This method is preferable to apply() when the result value isn’t needed, since it doesn’t require specifying a result type.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.