Struct serde_v8::Value[][src]

pub struct Value<'s> {
    pub v8_value: Local<'s, Value>,
}
Expand description

serde_v8::Value allows passing through v8::Values untouched when encoding/decoding and allows mixing rust & v8 values in structs, tuples… The implementation mainly breaks down to:

  1. Transmuting between u64 <> serde_v8::Value
  2. Using special struct/field names to detect these values
  3. Then serde “boilerplate”

Fields

v8_value: Local<'s, Value>

Trait Implementations

impl<'de, 's> Deserialize<'de> for Value<'s>[src]

fn deserialize<D>(deserializer: D) -> Result<Value<'s>, D::Error> where
    D: Deserializer<'de>, 
[src]

Deserialize this value from the given Serde deserializer. Read more

impl<'s> From<Local<'s, Value>> for Value<'s>[src]

fn from(v8_value: Local<'s, Value>) -> Self[src]

Performs the conversion.

impl Serialize for Value<'_>[src]

fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error> where
    S: Serializer
[src]

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

impl<'s> RefUnwindSafe for Value<'s>

impl<'s> !Send for Value<'s>

impl<'s> !Sync for Value<'s>

impl<'s> Unpin for Value<'s>

impl<'s> UnwindSafe for Value<'s>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

impl<T> From<T> for T[src]

pub fn from(t: T) -> T[src]

Performs the conversion.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

pub fn into(self) -> U[src]

Performs the conversion.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

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

Performs the conversion.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.

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

Performs the conversion.

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]