ITADN

How to convert JsonValue to String

#55ClosedDenineLu 创建于 2024-06-24
D
DenineLucommented
For DOM parser, how to convert JsonValue to byte array or string? For example: ```java byte[] json = toUtf8("{\"a\": {\"b\": \"c\"}}"); JsonValue jsonValue = parser.parse(json, json.length); JsonValue res = jsonValue.get("a"); ``` I want to get the string `{"b": "c"}`. Thank you in advance for your help with this question.
关闭于 2024-10-20 1 条评论