Expand description
Built-in merge
functions.
Functionsยง
- append_
vec - Append the items from the next vector to the end of the previous vector.
- discard
- Discard both previous and next values and return
None
. - merge_
btreemap - Shallow merge the next
BTreeMap
into the previousBTreeMap
. Any items in the nextBTreeMap
will overwrite items in the previousBTreeMap
of the same key. - merge_
btreeset - Shallow merge the next
BTreeSet
into the previousBTreeSet
, overwriting duplicates. - merge_
hashmap - Shallow merge the next
HashMap
into the previousHashMap
. Any items in the nextHashMap
will overwrite items in the previousHashMap
of the same key. - merge_
hashset - Shallow merge the next
HashSet
into the previousHashSet
, overwriting duplicates. - prepend_
vec - Prepend the items from the next vector to the start of the previous vector.
- preserve
- Always preserve the previous value over the next value.
- replace
- Always replace the previous value with the next value.