Function dynmsg::yaml_to_string

Function Documentation

std::string dynmsg::yaml_to_string(const YAML::Node &yaml, const bool double_quoted = false, const bool flow_style = false)

Convert YAML node to string.

Flow style is one-line, JSON-like. Non-flow style is block style, which is the normal multi-line style.

Parameters:
  • yaml – the YAML node

  • double_quoted – whether to double quote all keys and values or not

  • flow_style – whether to use flow-style or not

Returns:

the YAML node as a string