pub trait AnyExt {
Show 18 methods
// Required methods
fn from_string(s: String) -> Any;
fn from_str(s: &str) -> Any;
fn from_bool(b: bool) -> Any;
fn from_int32(i: i32) -> Any;
fn from_int64(i: i64) -> Any;
fn from_float(f: f32) -> Any;
fn from_double(d: f64) -> Any;
fn from_bytes(bytes: Vec<u8>) -> Any;
fn from_slice(slice: &[u8]) -> Any;
fn from_value<T: Into<AnyValue>>(value: T) -> Any;
fn is_string(&self) -> bool;
fn is_bool(&self) -> bool;
fn is_int32(&self) -> bool;
fn is_int64(&self) -> bool;
fn is_float(&self) -> bool;
fn is_double(&self) -> bool;
fn is_bytes(&self) -> bool;
fn is_unknown(&self) -> bool;
}Required Methods§
fn from_string(s: String) -> Any
fn from_str(s: &str) -> Any
fn from_bool(b: bool) -> Any
fn from_int32(i: i32) -> Any
fn from_int64(i: i64) -> Any
fn from_float(f: f32) -> Any
fn from_double(d: f64) -> Any
fn from_bytes(bytes: Vec<u8>) -> Any
fn from_slice(slice: &[u8]) -> Any
fn from_value<T: Into<AnyValue>>(value: T) -> Any
fn is_string(&self) -> bool
fn is_bool(&self) -> bool
fn is_int32(&self) -> bool
fn is_int64(&self) -> bool
fn is_float(&self) -> bool
fn is_double(&self) -> bool
fn is_bytes(&self) -> bool
fn is_unknown(&self) -> bool
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.