这里小雨.
        <!-- https://mvnrepository.com/artifact/com.alibaba/fastjson -->
        <dependency>
            <groupId>com.alibaba</groupId>
            <artifactId>fastjson</artifactId>
            <version>2.0.21</version>
        </dependency>

这样写的maven 但是getString parseObject很多方法用不了 是为什么啊




18618200653
666666666666666

美味的曲奇
具体什么方法用不了,错误是什么

这里小雨.
美味的曲奇 发表于 2022-12-28 18:47
具体什么方法用不了,错误是什么

getString方法用不了
    public static void main(String[] args) throws IOException {
        httpApi api = new httpApi();
        String run = api.run("xxx");
        JSONObject jsonObject = (JSONObject) JSON.parse(run);
        String content = JSON.getString("content");
        System.out.println(content);
    }

java: 找不到符号
  符号:   方法 getString()
  位置: 类型为org.json.simple.JSONObject的变量 js

第一页 上一页 下一页 最后一页