mozjs_
sys
0.140.0-3
jsid
Aliased Type
Fields
asBits_
Methods
asBits
is_gcthing
is_int
is_string
is_symbol
is_void
to_gcthing
to_int
to_string
to_symbol
Trait Implementations
Default
GCMethods
Initialize
RootKind
In mozjs_
sys::
jsapi
mozjs_sys
::
jsapi
Type Alias
jsid
Copy item path
Source
pub type jsid =
PropertyKey
;
Aliased Type
§
#[repr(C)]
pub struct jsid { pub asBits_:
usize
, }
Fields
§
§
asBits_:
usize
Implementations
§
Source
§
impl
jsid
Source
fn
asBits
(&self) ->
usize
Source
pub fn
is_void
(&self) ->
bool
Source
pub fn
is_int
(&self) ->
bool
Source
pub fn
is_string
(&self) ->
bool
Source
pub fn
is_symbol
(&self) ->
bool
Source
pub fn
is_gcthing
(&self) ->
bool
Source
pub fn
to_int
(&self) ->
i32
Source
pub fn
to_string
(&self) ->
*mut
JSString
Source
pub fn
to_symbol
(&self) ->
*mut
Symbol
Source
pub fn
to_gcthing
(&self) ->
*mut
c_void
Trait Implementations
§
Source
§
impl
Default
for
jsid
Source
§
fn
default
() -> Self
Returns the “default value” for a type.
Read more
Source
§
impl
GCMethods
for
jsid
Source
§
unsafe fn
post_barrier
(_:
*mut
jsid
, _:
jsid
, _:
jsid
)
Place a post-write barrier
Source
§
unsafe fn
initial
() -> Self
Create a default value
Source
§
impl
Initialize
for
jsid
Source
§
unsafe fn
initial
() ->
Option
<
jsid
>
Create a default value. If there is no meaningful default possible, returns None. SAFETY: The default must not be a value that can be meaningfully garbage collected.
Source
§
impl
RootKind
for
jsid
Source
§
const
VTABLE
: Self::
Vtable
= ()
Source
§
const
KIND
:
RootKind
= JS::RootKind::Id
Source
§
type
Vtable
=
()