(dumper, data)
return yaml.nodes.MappingNode(u'tag:yaml.org,2002:map', value)
Allows for OrderedDict to be written out to yaml.

    References:
        https://codedump.io/share/2MLFLtw3wnX7/1/can-pyyaml-dump-dict-items-in-non-alphabetical-order
        http://stackoverflow.com/questions/16782112/can-pyyaml-dump-dict-items-in-non-alphabetical-order
Allows for OrderedDict to be written out to yaml.
Allows for OrderedDict to be written out to yaml .
def __represent_ordereddict(dumper, data):
    """
    Allows for OrderedDict to be written out to yaml.

    References:
        https://codedump.io/share/2MLFLtw3wnX7/1/can-pyyaml-dump-dict-items-in-non-alphabetical-order
        http://stackoverflow.com/questions/16782112/can-pyyaml-dump-dict-items-in-non-alphabetical-order

    """
    value = []

    for item_key, item_value in data.items():
        node_key = dumper.represent_data(item_key)
        node_value = dumper.represent_data(item_value)

        value.append((node_key, node_value))

    return yaml.nodes.MappingNode(u'tag:yaml.org,2002:map', value)
def __represent_ordereddict ( dumper , data ) : value = [ ] for item_key , item_value in data . items ( ) : node_key = dumper . represent_data ( item_key ) node_value = dumper . represent_data ( item_value ) value . append ( ( node_key , node_value ) ) return yaml . nodes . MappingNode ( u'tag:yaml.org,2002:map' , value )