Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我的 gson 有问题,whitch 正在逃避我的字符串。
Gson gson = new GsonBuilder().disableHtmlEscaping().create(); String test = "\r\n"; JsonElement result = gson.toJsonTree(test); String string = gson.toJson(result);
在这个字符串之后是"\\r\\n"如何避免这种情况?
"\\r\\n"