Skip to main content

NativePathNode

Struct NativePathNode 

Source
pub struct NativePathNode {
    pub begin: u32,
    pub end: u32,
    pub word_id: i32,
    pub left_id: i32,
    pub right_id: i32,
    pub cost: i32,
    pub total_cost: i32,
    pub is_oov: bool,
    pub oov_pos_id: Option<i32>,
}
Expand description

PathNode returned to JS.

Fields§

§begin: u32§end: u32§word_id: i32§left_id: i32§right_id: i32§cost: i32§total_cost: i32§is_oov: bool§oov_pos_id: Option<i32>

Trait Implementations§

Source§

impl FromNapiValue for NativePathNode

Source§

unsafe fn from_napi_value( env: napi_env, napi_val: napi_value, ) -> Result<NativePathNode>

Safety Read more
Source§

fn from_unknown(value: Unknown<'_>) -> Result<Self, Error>

Source§

impl Serialize for NativePathNode

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl ToNapiValue for NativePathNode

Source§

impl TypeName for NativePathNode

Source§

impl ValidateNapiValue for NativePathNode

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> JsValuesTupleIntoVec for T
where T: ToNapiValue,

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.