pub enum Object {
Null,
Boolean(bool),
Integer(i64),
Real(f64),
String(String),
Name(String),
Array(Vec<Object>),
Dictionary(Dictionary),
Stream(Dictionary, Vec<u8>),
Reference(ObjectId),
}Variants§
Null
Boolean(bool)
Integer(i64)
Real(f64)
String(String)
Name(String)
Array(Vec<Object>)
Dictionary(Dictionary)
Stream(Dictionary, Vec<u8>)
Reference(ObjectId)
Implementations§
Source§impl Object
impl Object
pub fn is_null(&self) -> bool
pub fn as_bool(&self) -> Option<bool>
pub fn as_integer(&self) -> Option<i64>
pub fn as_real(&self) -> Option<f64>
pub fn as_string(&self) -> Option<&str>
pub fn as_name(&self) -> Option<&str>
pub fn as_array(&self) -> Option<&Vec<Object>>
pub fn as_dict(&self) -> Option<&Dictionary>
Trait Implementations§
Source§impl From<Dictionary> for Object
impl From<Dictionary> for Object
Source§fn from(d: Dictionary) -> Self
fn from(d: Dictionary) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for Object
impl RefUnwindSafe for Object
impl Send for Object
impl Sync for Object
impl Unpin for Object
impl UnwindSafe for Object
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more