[][src]Enum rant::value::RantValue

pub enum RantValue {
    String(String),
    Float(f64),
    Integer(i64),
    Boolean(bool),
    Function(Rc<RantFunction>),
    List(RantListRef),
    Map(RantMapRef),
    Empty,
}

Rant variable value.

Variants

String(String)
Float(f64)
Integer(i64)
Boolean(bool)
Function(Rc<RantFunction>)
Empty

Implementations

impl RantValue[src]

pub fn nan() -> Self[src]

pub fn is_empty(&self) -> bool[src]

impl RantValue[src]

pub fn into_rant_int(self) -> RantValue[src]

pub fn into_rant_float(self) -> RantValue[src]

pub fn into_rant_string(self) -> RantValue[src]

pub fn len(&self) -> usize[src]

pub fn type_name(&self) -> &'static str[src]

Gets the type name of the value.

pub fn get_by_index(&self, index: i64) -> ValueIndexResult[src]

pub fn set_by_index(
    &mut self,
    index: i64,
    val: RantValue
) -> ValueIndexSetResult
[src]

pub fn get_by_key(&self, key: &str) -> ValueKeyResult[src]

pub fn set_by_key(&mut self, key: &str, val: RantValue) -> ValueKeySetResult[src]

Trait Implementations

impl Add<RantValue> for RantValue[src]

type Output = RantValue

The resulting type after applying the + operator.

impl Clone for RantValue[src]

impl Debug for RantValue[src]

impl Default for RantValue[src]

impl Display for RantValue[src]

impl Div<RantValue> for RantValue[src]

type Output = ValueResult<RantValue>

The resulting type after applying the / operator.

impl Eq for RantValue[src]

impl FromIterator<RantValue> for RantList[src]

impl FromRant for RantValue[src]

impl Mul<RantValue> for RantValue[src]

type Output = RantValue

The resulting type after applying the * operator.

impl Neg for RantValue[src]

type Output = RantValue

The resulting type after applying the - operator.

impl Not for RantValue[src]

type Output = Self

The resulting type after applying the ! operator.

impl PartialEq<RantValue> for RantValue[src]

impl PartialOrd<RantValue> for RantValue[src]

impl Rem<RantValue> for RantValue[src]

type Output = ValueResult<RantValue>

The resulting type after applying the % operator.

impl Sub<RantValue> for RantValue[src]

type Output = RantValue

The resulting type after applying the - operator.

Auto Trait Implementations

impl !RefUnwindSafe for RantValue

impl !Send for RantValue

impl !Sync for RantValue

impl Unpin for RantValue

impl !UnwindSafe for RantValue

Blanket Implementations

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

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

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

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

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

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

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.

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.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,