Skip to main content

HashElement

Struct HashElement 

Source
pub struct HashElement {
    pub key: String,
    pub value: AliasedYaml,
}

Fields§

§key: String§value: AliasedYaml

Trait Implementations§

Source§

impl Clone for HashElement

Source§

fn clone(&self) -> HashElement

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for HashElement

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl MapYaml for HashElement

Source§

fn map_yaml<F: FnMut(Yaml) -> Yaml>(self, f: &mut F) -> Self

Source§

impl PartialEq for HashElement

Source§

fn eq(&self, other: &HashElement) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl Pretty for HashElement

Source§

fn pretty_with_options(self, in_inline: bool, _child_of_array: bool) -> Self

Source§

fn pretty(self) -> Self
where Self: Sized,

Source§

impl StructuralPartialEq for HashElement

Source§

impl VisitYaml for HashElement

Source§

impl YamlInsert for HashElement

Source§

fn edit_hash_structure<F>(&mut self, path: &YamlPath, f: &F) -> usize
where F: Fn(&mut Vec<HashData>, String, Option<usize>) -> usize,

Source§

fn for_hash<F, R, A: Additive>(&mut self, path: &YamlPath, f: &F, r: &R) -> A
where F: Fn(&mut HashElement) -> A, R: Fn(&mut Yaml) -> A,

Source§

fn find_values(&mut self, path: &YamlPath) -> MyVec<Yaml>

Find values
Source§

fn insert_into_hash( &mut self, path: &YamlPath, h: &AliasedYaml, overwrite: bool, ) -> usize

Insert AliasedYaml into a hash Returns the amount of insertions. Can be more than 1 when using indexes or all array elements etc
Source§

fn insert_into_hash_by_call<F>( &mut self, path: &YamlPath, h: F, overwrite: bool, ) -> usize
where F: Fn() -> AliasedYaml,

Source§

fn remove_from_hash(&mut self, path: &YamlPath) -> usize

Source§

fn rename_field(&mut self, path: &YamlPath, new_name: String) -> usize

Source§

fn to_object(&mut self, path: &YamlPath, object_key: String) -> usize

Source§

fn move_to_subfield( &mut self, path: &YamlPath, subfield: String, fields_to_move: Vec<String>, ) -> usize

Source§

fn move_to_map_with_field_as_key( &mut self, path: &YamlPath, old_map_name: String, selector: String, new_map_name: String, keeps: Vec<String>, ) -> usize

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.