[][src]Crate yaml_merge_keys

YAML Merge Keys

The YAML Merge Key extension is not supported by the core YAML crate, but can be implemented after parsing. This crate transforms a parsed YAML document and merges dictionaries together.

Example

---
- &CENTER { x: 1, y: 2 }
- &LEFT { x: 0, y: 2 }
- &BIG { r: 10 }
- &SMALL { r: 1 }

# All the following maps are equal:

- # Explicit keys
  x: 1
  y: 2
  r: 10
  label: center/big

- # Merge one map
  << : *CENTER
  r: 10
  label: center/big

- # Merge multiple maps
  << : [ *CENTER, *BIG ]
  label: center/big

- # Override
  << : [ *BIG, *LEFT, *SMALL ]
  x: 1
  label: center/big

Structs

Error

The Error type.

Enums

ErrorKind

The kind of an error.

Traits

ResultExt

Additional methods for Result, for easy interaction with this crate.

Functions

merge_keys

Handle merge keys in a YAML document.

merge_keys_serde

Handle merge keys in a serde YAML document.

Type Definitions

Result

Convenient wrapper around std::Result.