Struct liquid_value::Index [−][src]
pub struct Index { /* fields omitted */ }
An index into a liquid_value::Value
.
Methods
impl Index
[src]
impl Index
pub fn with_key<S: Into<String>>(key: S) -> Self
[src]
pub fn with_key<S: Into<String>>(key: S) -> Self
Create an Object
Index
.
pub fn with_index(index: isize) -> Self
[src]
pub fn with_index(index: isize) -> Self
Create an Array
Index
.
pub fn is_key(&self) -> bool
[src]
pub fn is_key(&self) -> bool
Check if Object
Index
.
pub fn is_index(&self) -> bool
[src]
pub fn is_index(&self) -> bool
Check if Array
Index
.
pub fn as_key(&self) -> Option<&str>
[src]
pub fn as_key(&self) -> Option<&str>
Return the Object
Index
.
pub fn as_index(&self) -> Option<isize>
[src]
pub fn as_index(&self) -> Option<isize>
Return the Array
Index
.
Trait Implementations
impl Clone for Index
[src]
impl Clone for Index
fn clone(&self) -> Index
[src]
fn clone(&self) -> Index
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0
[src]Performs copy-assignment from source
. Read more
impl Debug for Index
[src]
impl Debug for Index
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl Eq for Index
[src]
impl Eq for Index
impl PartialEq for Index
[src]
impl PartialEq for Index
fn eq(&self, other: &Index) -> bool
[src]
fn eq(&self, other: &Index) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Index) -> bool
[src]
fn ne(&self, other: &Index) -> bool
This method tests for !=
.
impl Hash for Index
[src]
impl Hash for Index
fn hash<__H: Hasher>(&self, state: &mut __H)
[src]
fn hash<__H: Hasher>(&self, state: &mut __H)
Feeds this value into the given [Hasher
]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0
[src]Feeds a slice of this type into the given [Hasher
]. Read more
impl Display for Index
[src]
impl Display for Index
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl From<isize> for Index
[src]
impl From<isize> for Index
impl From<String> for Index
[src]
impl From<String> for Index
impl<'a> From<&'a str> for Index
[src]
impl<'a> From<&'a str> for Index
impl Extend<Index> for Path
[src]
impl Extend<Index> for Path
fn extend<T: IntoIterator<Item = Index>>(&mut self, iter: T)
[src]
fn extend<T: IntoIterator<Item = Index>>(&mut self, iter: T)
Extends a collection with the contents of an iterator. Read more
impl FromIterator<Index> for Path
[src]
impl FromIterator<Index> for Path
fn from_iter<I>(iter: I) -> Self where
I: IntoIterator<Item = Index>,
[src]
fn from_iter<I>(iter: I) -> Self where
I: IntoIterator<Item = Index>,
Creates a value from an iterator. Read more