JSON-to-XML parser in C ++ successfully parses the json object into its components, but this object instead of Cyrillic contains coded characters like "\ u0410". It is necessary to convert these characters into normal letters for writing to an XML file.

Of course, I have an idea - to build a map characters and analyze the string, but maybe there is some function for converting the string in such a way as not to reinvent the wheel?

  • one
    In json, both "А" and "\u0410" represent the same symbol A (U + 0410). If the parser does not understand \ u0410, then this is not a json parser. - jfs
  • In general, I made a comparison of substrings with the values ​​of the map <string, string> keys, for example, the key "\\ u0410", the value "A" - and so on for the entire alphabet. Clumsy, but it works) - Iceman
  • Json is not difficult to recognize, but why write yourself if there are already a lot of json libraries for c ++, including header-only - jfs

0