Using JYaml 1.3 and 1.2, I tried to parse a YAML file (see test1.yml attachment). I got an "End of document expected" parser error from JYaml.
When I modified the YAML file (see test2.yml attachment), it reads the document as a list of 2 maps with each map corresponding to the sequence under the organizations mapping.
It should have read test1.yml as a list of maps, and test2.yml as a map with 1 entry which would be a list of maps.
I parsed these same documents with Snake-YAML 1.3 and it worked as expected.
I attached the code I used to load these documents (see JYamlTest.java attachment).
Log in to post a comment.