Enum rs_es::units::JsonVal [] [src]

pub enum JsonVal {
    String(String),
    I64(i64),
    U64(u64),
    F64(f64),
    Boolean(bool),
}

A Json value that's not a structural thing - i.e. just String, i64 and f64, no array or object

Variants

String(String)I64(i64)U64(u64)F64(f64)Boolean(bool)

Methods

impl JsonVal
[src]

fn from(from: &Value) -> Result<Self, EsError>

Trait Implementations

impl Debug for JsonVal
[src]

fn fmt(&self, __arg_0: &mut Formatter) -> Result

Formats the value using the given formatter.

impl Default for JsonVal
[src]

fn default() -> Self

Returns the "default value" for a type. Read more

impl Serialize for JsonVal
[src]

fn serialize<S>(&self, serializer: &mut S) -> Result<(), S::Error> where S: Serializer

Serializes this value into this serializer.

impl Deserialize for JsonVal
[src]

fn deserialize<D>(deserializer: &mut D) -> Result<JsonVal, D::Error> where D: Deserializer

Deserialize this value given this Deserializer.

impl From<String> for JsonVal
[src]

fn from(from: String) -> JsonVal

Performs the conversion.

impl<'a> From<&'a str> for JsonVal
[src]

fn from(from: &'a str) -> JsonVal

Performs the conversion.

impl From<f32> for JsonVal
[src]

fn from(from: f32) -> JsonVal

Performs the conversion.

impl From<f64> for JsonVal
[src]

fn from(from: f64) -> JsonVal

Performs the conversion.

impl From<i32> for JsonVal
[src]

fn from(from: i32) -> JsonVal

Performs the conversion.

impl From<i64> for JsonVal
[src]

fn from(from: i64) -> JsonVal

Performs the conversion.

impl From<u32> for JsonVal
[src]

fn from(from: u32) -> JsonVal

Performs the conversion.

impl From<u64> for JsonVal
[src]

fn from(from: u64) -> JsonVal

Performs the conversion.

impl From<bool> for JsonVal
[src]

fn from(from: bool) -> JsonVal

Performs the conversion.

impl<'a> From<&'a Value> for JsonVal
[src]

fn from(from: &'a Value) -> Self

Performs the conversion.