Struct napi::CallContext [−][src]
Expand description
Function call context
Fields
env: &'env mut Envlength: usizearguments.length
Implementations
impl<'env> CallContext<'env>[src]
impl<'env> CallContext<'env>[src]pub fn new(
env: &'env mut Env,
callback_info: napi_callback_info,
raw_this: napi_value,
args: &'env [napi_value],
length: usize
) -> Self[src]
env: &'env mut Env,
callback_info: napi_callback_info,
raw_this: napi_value,
args: &'env [napi_value],
length: usize
) -> Self
pub fn get<ArgType: NapiValue>(&self, index: usize) -> Result<ArgType>[src]
pub fn try_get<ArgType: NapiValue>(
&self,
index: usize
) -> Result<Either<ArgType, JsUndefined>>[src]
&self,
index: usize
) -> Result<Either<ArgType, JsUndefined>>
pub fn get_all(&self) -> Vec<JsUnknown>[src]
pub fn get_new_target<V>(&self) -> Result<V> where
V: NapiValue, [src]
V: NapiValue,