Struct serde_yaml::Mapping [−][src]
pub struct Mapping { /* fields omitted */ }
A YAML mapping in which the keys and values are both serde_yaml::Value
.
Methods
impl Mapping
[src]
impl Mapping
pub fn new() -> Self
[src]
pub fn new() -> Self
pub fn with_capacity(capacity: usize) -> Self
[src]
pub fn with_capacity(capacity: usize) -> Self
pub fn reserve(&mut self, additional: usize)
[src]
pub fn reserve(&mut self, additional: usize)
pub fn shrink_to_fit(&mut self)
[src]
pub fn shrink_to_fit(&mut self)
pub fn insert(&mut self, k: Value, v: Value) -> Option<Value>
[src]
pub fn insert(&mut self, k: Value, v: Value) -> Option<Value>
pub fn contains_key(&self, k: &Value) -> bool
[src]
pub fn contains_key(&self, k: &Value) -> bool
pub fn get(&self, k: &Value) -> Option<&Value>
[src]
pub fn get(&self, k: &Value) -> Option<&Value>
pub fn get_mut(&mut self, k: &Value) -> Option<&mut Value>
[src]
pub fn get_mut(&mut self, k: &Value) -> Option<&mut Value>
pub fn remove(&mut self, k: &Value) -> Option<Value>
[src]
pub fn remove(&mut self, k: &Value) -> Option<Value>
pub fn capacity(&self) -> usize
[src]
pub fn capacity(&self) -> usize
pub fn len(&self) -> usize
[src]
pub fn len(&self) -> usize
pub fn is_empty(&self) -> bool
[src]
pub fn is_empty(&self) -> bool
pub fn clear(&mut self)
[src]
pub fn clear(&mut self)
pub fn iter(&self) -> Iter
[src]
pub fn iter(&self) -> Iter
pub fn iter_mut(&mut self) -> IterMut
[src]
pub fn iter_mut(&mut self) -> IterMut
Trait Implementations
impl Clone for Mapping
[src]
impl Clone for Mapping
fn clone(&self) -> Mapping
[src]
fn clone(&self) -> Mapping
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)
Performs copy-assignment from source
. Read more
impl Debug for Mapping
[src]
impl Debug for Mapping
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 Default for Mapping
[src]
impl Default for Mapping
impl Eq for Mapping
[src]
impl Eq for Mapping
impl Hash for Mapping
[src]
impl Hash for Mapping
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,
Feeds a slice of this type into the given [Hasher
]. Read more
impl PartialEq for Mapping
[src]
impl PartialEq for Mapping
fn eq(&self, other: &Mapping) -> bool
[src]
fn eq(&self, other: &Mapping) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Mapping) -> bool
[src]
fn ne(&self, other: &Mapping) -> bool
This method tests for !=
.
impl PartialOrd for Mapping
[src]
impl PartialOrd for Mapping
fn partial_cmp(&self, other: &Mapping) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &Mapping) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &Mapping) -> bool
[src]
fn lt(&self, other: &Mapping) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &Mapping) -> bool
[src]
fn le(&self, other: &Mapping) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &Mapping) -> bool
[src]
fn gt(&self, other: &Mapping) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &Mapping) -> bool
[src]
fn ge(&self, other: &Mapping) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl<'a> Index<&'a Value> for Mapping
[src]
impl<'a> Index<&'a Value> for Mapping
type Output = Value
The returned type after indexing.
fn index(&self, index: &'a Value) -> &Value
[src]
fn index(&self, index: &'a Value) -> &Value
Performs the indexing (container[index]
) operation.
impl<'a> IndexMut<&'a Value> for Mapping
[src]
impl<'a> IndexMut<&'a Value> for Mapping
fn index_mut(&mut self, index: &'a Value) -> &mut Value
[src]
fn index_mut(&mut self, index: &'a Value) -> &mut Value
Performs the mutable indexing (container[index]
) operation.
impl Extend<(Value, Value)> for Mapping
[src]
impl Extend<(Value, Value)> for Mapping
fn extend<I: IntoIterator<Item = (Value, Value)>>(&mut self, iter: I)
[src]
fn extend<I: IntoIterator<Item = (Value, Value)>>(&mut self, iter: I)
Extends a collection with the contents of an iterator. Read more
impl FromIterator<(Value, Value)> for Mapping
[src]
impl FromIterator<(Value, Value)> for Mapping
fn from_iter<I: IntoIterator<Item = (Value, Value)>>(iter: I) -> Self
[src]
fn from_iter<I: IntoIterator<Item = (Value, Value)>>(iter: I) -> Self
Creates a value from an iterator. Read more
impl<'a> IntoIterator for &'a Mapping
[src]
impl<'a> IntoIterator for &'a Mapping
type Item = (&'a Value, &'a Value)
The type of the elements being iterated over.
type IntoIter = Iter<'a>
Which kind of iterator are we turning this into?
fn into_iter(self) -> Self::IntoIter
[src]
fn into_iter(self) -> Self::IntoIter
Creates an iterator from a value. Read more
impl<'a> IntoIterator for &'a mut Mapping
[src]
impl<'a> IntoIterator for &'a mut Mapping
type Item = (&'a Value, &'a mut Value)
The type of the elements being iterated over.
type IntoIter = IterMut<'a>
Which kind of iterator are we turning this into?
fn into_iter(self) -> Self::IntoIter
[src]
fn into_iter(self) -> Self::IntoIter
Creates an iterator from a value. Read more
impl IntoIterator for Mapping
[src]
impl IntoIterator for Mapping
type Item = (Value, Value)
The type of the elements being iterated over.
type IntoIter = IntoIter
Which kind of iterator are we turning this into?
fn into_iter(self) -> Self::IntoIter
[src]
fn into_iter(self) -> Self::IntoIter
Creates an iterator from a value. Read more
impl Serialize for Mapping
[src]
impl Serialize for Mapping
fn serialize<S: Serializer>(&self, serializer: S) -> Result<S::Ok, S::Error>
[src]
fn serialize<S: Serializer>(&self, serializer: S) -> Result<S::Ok, S::Error>
Serialize this value into the given Serde serializer. Read more
impl<'de> Deserialize<'de> for Mapping
[src]
impl<'de> Deserialize<'de> for Mapping
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error> where
D: Deserializer<'de>,
[src]
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error> where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl From<Mapping> for Value
[src]
impl From<Mapping> for Value