feat(napi): impl get_value for Boolean
This commit is contained in:
parent
c1da4f8d8e
commit
57b319273c
1 changed files with 6 additions and 0 deletions
|
@ -780,6 +780,12 @@ fn get_raw_type(env: sys::napi_env, raw_value: sys::napi_value) -> sys::napi_val
|
|||
}
|
||||
}
|
||||
|
||||
impl<'env> Value<'env, Boolean> {
|
||||
pub fn get_value(&self) -> bool {
|
||||
self.value.value
|
||||
}
|
||||
}
|
||||
|
||||
impl<'env> Value<'env, JsString> {
|
||||
pub fn len(&self) -> Result<usize> {
|
||||
let mut raw_length = ptr::null_mut();
|
||||
|
|
Loading…
Reference in a new issue