[−][src]Struct handlebars::PathAndJson
Json wrapper that holds the Json value and reference path information
Methods
impl<'reg: 'rc, 'rc> PathAndJson<'reg, 'rc>[src]
pub fn new(
path: Option<String>,
value: ScopedJson<'reg, 'rc>
) -> PathAndJson<'reg, 'rc>[src]
path: Option<String>,
value: ScopedJson<'reg, 'rc>
) -> PathAndJson<'reg, 'rc>
pub fn new_absolute(
path: Option<String>,
value: ScopedJson<'reg, 'rc>
) -> PathAndJson<'reg, 'rc>[src]
path: Option<String>,
value: ScopedJson<'reg, 'rc>
) -> PathAndJson<'reg, 'rc>
pub fn path(&self) -> Option<&String>[src]
Returns relative path when the value is referenced
If the value is from a literal, the path is None
pub fn path_root(&self) -> Option<&str>[src]
Return root level of this path if any
pub fn is_absolute_path(&self) -> bool[src]
pub fn value(&self) -> &Json[src]
Returns the value
pub fn is_value_missing(&self) -> bool[src]
Test if value is missing
pub fn render(&self) -> String[src]
Trait Implementations
impl<'reg: 'rc, 'rc> Debug for PathAndJson<'reg, 'rc>[src]
Auto Trait Implementations
impl<'reg, 'rc> Send for PathAndJson<'reg, 'rc>
impl<'reg, 'rc> Sync for PathAndJson<'reg, 'rc>
impl<'reg, 'rc> Unpin for PathAndJson<'reg, 'rc>
impl<'reg, 'rc> UnwindSafe for PathAndJson<'reg, 'rc>
impl<'reg, 'rc> RefUnwindSafe for PathAndJson<'reg, 'rc>
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>, [src]
U: From<T>,
impl<T> From<T> for T[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>, [src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>, [src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]
impl<T> Borrow<T> for T where
T: ?Sized, [src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T[src]
impl<T> Any for T where
T: 'static + ?Sized, [src]
T: 'static + ?Sized,