Type Definition mozjs::jsval::JSVal
[−]
[src]
type JSVal = Value;
Methods
impl JSVal[src]
pub fn is_undefined(&self) -> bool[src]
pub fn is_null(&self) -> bool[src]
pub fn is_null_or_undefined(&self) -> bool[src]
pub fn is_boolean(&self) -> bool[src]
pub fn is_int32(&self) -> bool[src]
pub fn is_double(&self) -> bool[src]
pub fn is_number(&self) -> bool[src]
pub fn is_primitive(&self) -> bool[src]
pub fn is_string(&self) -> bool[src]
pub fn is_object(&self) -> bool[src]
pub fn is_symbol(&self) -> bool[src]
pub fn to_boolean(&self) -> bool[src]
pub fn to_int32(&self) -> i32[src]
pub fn to_double(&self) -> f64[src]
pub fn to_number(&self) -> f64[src]
pub fn to_object(&self) -> *mut JSObject[src]
pub fn to_string(&self) -> *mut JSString[src]
pub fn is_object_or_null(&self) -> bool[src]
pub fn to_object_or_null(&self) -> *mut JSObject[src]
pub fn to_private(&self) -> *const c_void[src]
pub fn is_gcthing(&self) -> bool[src]
pub fn to_gcthing(&self) -> *mut c_void[src]
pub fn is_markable(&self) -> bool[src]
pub fn trace_kind(&self) -> TraceKind[src]
Trait Implementations
impl FromJSValConvertible for JSVal[src]
type Config = ()
Optional configurable behaviour switch; use () for no configuration.
unsafe fn from_jsval(
_cx: *mut JSContext,
value: HandleValue,
_option: ()
) -> Result<ConversionResult<JSVal>, ()>[src]
_cx: *mut JSContext,
value: HandleValue,
_option: ()
) -> Result<ConversionResult<JSVal>, ()>
Convert val to type Self. Optional configuration of type T can be passed as the option argument. If it returns Err(()), a JSAPI exception is pending. If it returns Ok(Failure(reason)), there is no pending JSAPI exception. Read more
impl ToJSValConvertible for JSVal[src]
unsafe fn to_jsval(&self, cx: *mut JSContext, rval: MutableHandleValue)[src]
Convert self to a JSVal. JSAPI failure causes a panic.