com.alibaba.fastjson.JSONException: expect ':' at 0, actual "
at com.alibaba.fastjson.parser.DefaultJSONParser.parseObject(DefaultJSONParser.java:290)
at com.alibaba.fastjson.parser.DefaultJSONParser.parse(DefaultJSONParser.java:1367)
at com.alibaba.fastjson.parser.DefaultJSONParser.parse(DefaultJSONParser.java:1333)
at com.alibaba.fastjson.JSON.parse(JSON.java:152)
at com.alibaba.fastjson.JSON.parse(JSON.java:162)
at com.alibaba.fastjson.JSON.parse(JSON.java:131)
at com.alibaba.fastjson.JSON.parseObject(JSON.java:223)
at com.fastonetech.service.impl.FileRechargeService.processingFile(FileRechargeService.kt:36)
at com.fastonetech.listener.fileRecharge.FileActionCallback.create(FileActionCallback.kt:45)
at com.fastonetech.listener.fileRecharge.WatchDir.processEvents(WatchDir.kt:71)
at com.fastonetech.listener.fileRecharge.WatchDir.<init>(WatchDir.kt:108)
at com.fastonetech.init.AccountInit.createDirectorie$lambda-0(AccountInit.kt:85)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:834)
com.alibaba.fastjson.JSONException 出现这个错误JSONException: expect ‘:’ at 0, actual "
json格式为:
{“payType”:“SYSTEM”,"account":2000,"remark":"2021-10-21给张三丰12账户充值"}
将json的中文字符修改为英文字符
{"payType":"SYSTEM","account":2000,"remark":"2021-10-21给张三丰12账户充值"}
版权说明 : 本文为转载文章, 版权归原作者所有 版权申明
原文链接 : https://blog.csdn.net/sunyuhua_keyboard/article/details/120923029
内容来源于网络,如有侵权,请联系作者删除!