code: public static YamlNode load(String yaml, String rootName) {
          try {
              Object document = getLoad().loadFromString(yaml);
              return buildDom(rootName, document);
          } catch (Exception ex) {
              throw new YamlException("An error occurred while loading and parsing the YAML string", ex);
          }
      }
docs: Loads a YAML document from an {@link String} and builds a
  {@link YamlNode} tree that is under the provided top-level
  {@code rootName} key. This loading mode requires the topmost level
  of the YAML document to be a mapping.
  
  @param yaml     The string to load the YAML from
  @param rootName The name of the root's key
  @return the tree built from the YAML document