Struct neon::types::JsUndefined
source · pub struct JsUndefined(/* private fields */);
Expand description
The type of JavaScript
undefined
primitives.
§Example
// Extract the console object:
let console: Handle<JsObject> = cx.global("console")?;
// The undefined value:
let undefined = cx.undefined();
// Call console.log(undefined):
console.call_method_with(&mut cx, "log")?.arg(undefined).exec(&mut cx)?;
Implementations§
source§impl JsUndefined
impl JsUndefined
sourcepub fn new<'a, C: Context<'a>>(cx: &mut C) -> Handle<'a, JsUndefined>
pub fn new<'a, C: Context<'a>>(cx: &mut C) -> Handle<'a, JsUndefined>
Creates an undefined
value.
Although this method can be called many times, all undefined
values are indistinguishable.
See also: Context::undefined
Trait Implementations§
source§impl Debug for JsUndefined
impl Debug for JsUndefined
source§impl Value for JsUndefined
impl Value for JsUndefined
Auto Trait Implementations§
impl Freeze for JsUndefined
impl RefUnwindSafe for JsUndefined
impl !Send for JsUndefined
impl !Sync for JsUndefined
impl Unpin for JsUndefined
impl UnwindSafe for JsUndefined
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