Object

Trait Object 

Source
pub trait Object: Any {
Show 14 methods // Required methods fn as_any(&self) -> &dyn Any; fn as_any_mut(&mut self) -> &mut dyn Any; // Provided methods fn type_name(&self) -> &'static str { ... } fn get_member(&self, name: &str) -> Result<Value> { ... } fn get_index(&self, index: i64) -> Result<Value> { ... } fn get_key_value(&self, key: &str) -> Result<Value> { ... } fn as_string(&self) -> Option<String> { ... } fn as_float(&self) -> Option<f64> { ... } fn as_int(&self) -> Option<i64> { ... } fn as_bool(&self) -> Option<bool> { ... } fn call(&self, _args: &[Value]) -> Result<Value> { ... } fn equals(&self, _other: &Value) -> bool { ... } fn display(&self) -> String { ... } fn debug(&self) -> String { ... }
}

Required Methods§

Source

fn as_any(&self) -> &dyn Any

Source

fn as_any_mut(&mut self) -> &mut dyn Any

Provided Methods§

Source

fn type_name(&self) -> &'static str

Source

fn get_member(&self, name: &str) -> Result<Value>

Source

fn get_index(&self, index: i64) -> Result<Value>

Source

fn get_key_value(&self, key: &str) -> Result<Value>

Source

fn as_string(&self) -> Option<String>

Source

fn as_float(&self) -> Option<f64>

Source

fn as_int(&self) -> Option<i64>

Source

fn as_bool(&self) -> Option<bool>

Source

fn call(&self, _args: &[Value]) -> Result<Value>

Source

fn equals(&self, _other: &Value) -> bool

Source

fn display(&self) -> String

Source

fn debug(&self) -> String

Trait Implementations§

Source§

impl Debug for dyn Object

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Display for dyn Object

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Implementors§