[][src]Struct uclicious::raw::object::ObjectRef

pub struct ObjectRef { /* fields omitted */ }

An immutable reference to UCL Object structure. Provides most of the libUCL interface for interacting with parser results.

Methods

impl ObjectRef[src]

pub fn as_mut_ptr(&mut self) -> *mut ucl_object_t[src]

Return mutable pointer to inner struct.

pub fn as_ptr(&self) -> *const ucl_object_t[src]

Return const pointer to inner struct.

pub fn deep_copy(&self) -> Object[src]

Perform a deep copy

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

Returns true if this object is a null.

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

Returns true if this object is an object (think hashmap).

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

Returns true if this object is a string.

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

Returns true if this object is an integer.

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

Returns true if this object is a float.

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

Returns true if this object is a boolean type.

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

Returns true if this object is an array.

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

Returns true if this object is a time/duration.

pub fn priority(&self) -> Priority[src]

Get priority assigned to the object.

pub fn kind(&self) -> ucl_type_t[src]

Get type/kind of given object

pub fn key(&self) -> Option<String>[src]

Get key assigned to the object

pub fn lookup<K: AsRef<str>>(&self, key: K) -> Option<ObjectRef>[src]

Lookup a key within an object with type Object.

pub fn lookup_path<K: AsRef<str>>(&self, path: K) -> Option<ObjectRef>[src]

Perform a nested lookup with dot notation.

pub fn as_string(&self) -> Option<String>[src]

Return string value or None.

pub fn as_i64(&self) -> Option<i64>[src]

Return an integer value or None.

pub fn as_time(&self) -> Option<f64>[src]

Return a float number of seconds. Only works if object is time.

pub fn as_f64(&self) -> Option<f64>[src]

Return a float value or None. This function also works on time object.

pub fn as_bool(&self) -> Option<bool>[src]

Return a boolean value or None.

pub fn as_null(&self) -> Option<()>[src]

Return () or None.

pub fn iter(&self) -> Iter[src]

Preferred way to construct an iterator. Items returned by this iterator are always ObjectRef.

Trait Implementations

impl AsRef<ObjectRef> for Object[src]

impl Borrow<ObjectRef> for Object[src]

impl Debug for ObjectRef[src]

impl Eq for ObjectRef[src]

impl FromObject<ObjectRef> for i64[src]

impl FromObject<ObjectRef> for u64[src]

impl FromObject<ObjectRef> for ()[src]

impl FromObject<ObjectRef> for String[src]

impl FromObject<ObjectRef> for PathBuf[src]

impl FromObject<ObjectRef> for SocketAddr[src]

impl<T> FromObject<ObjectRef> for Vec<T> where
    T: FromObject<ObjectRef>, 
[src]

impl<T> FromObject<ObjectRef> for Option<T> where
    T: FromObject<ObjectRef>, 
[src]

impl<T, S> FromObject<ObjectRef> for HashMap<String, T, S> where
    T: FromObject<ObjectRef> + Clone,
    S: BuildHasher + Default
[src]

impl FromObject<ObjectRef> for Duration[src]

impl FromObject<ObjectRef> for i32[src]

impl FromObject<ObjectRef> for u32[src]

impl FromObject<ObjectRef> for i16[src]

impl FromObject<ObjectRef> for u16[src]

impl FromObject<ObjectRef> for i8[src]

impl FromObject<ObjectRef> for u8[src]

impl FromObject<ObjectRef> for f64[src]

impl FromObject<ObjectRef> for bool[src]

impl<'data> IntoIterator for &'data ObjectRef[src]

type Item = ObjectRef

The type of the elements being iterated over.

type IntoIter = Iter<'data>

Which kind of iterator are we turning this into?

impl IntoIterator for ObjectRef[src]

type Item = ObjectRef

The type of the elements being iterated over.

type IntoIter = IntoIter

Which kind of iterator are we turning this into?

impl Ord for ObjectRef[src]

impl PartialEq<ObjectRef> for ObjectRef[src]

impl PartialOrd<ObjectRef> for ObjectRef[src]

impl StructuralEq for ObjectRef[src]

impl ToOwned for ObjectRef[src]

type Owned = Object

The resulting type after obtaining ownership.

Auto Trait Implementations

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<I> IntoIterator for I where
    I: Iterator
[src]

type Item = <I as Iterator>::Item

The type of the elements being iterated over.

type IntoIter = I

Which kind of iterator are we turning this into?

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

type Owned = T

The resulting type after obtaining ownership.

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: FromObject<T>, 
[src]

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.