代码拉取完成,页面将自动刷新
HiJson is a lightweight JSON parsing library that can be used for HarmonyOS, Android, and Java
Gradle
implementation 'org.devio.hi.json:hijson:1.0.0'
Maven
<dependency>
<groupId>org.devio.hi.json</groupId>
<artifactId>hijson</artifactId>
<version>1.0.0</version>
</dependency>
Use like so:
jsonString:
{
"status": "1",
"count": "1",
"info": "OK",
"infocode": "10000",
"lives": [
{
"province": "河北",
"city": "邢台市",
"adcode": "130500",
"weather": "多云",
"temperature": "17",
"winddirection": "北",
"windpower": "≤3",
"humidity": "98",
"reporttime": "2020-09-26 21:58:34"
}
]
}
String city = new HiJson(jsonString).get("lives").get(0).value("city");
System.out.println(city);
Issues are welcome. Please add a screenshot of you bug and a code snippet. Quickest way to solve issue is to reproduce it in one of the examples.
Pull requests are welcome. If you want to change the API or do something big it is best to create an issue and discuss it first.
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。
1. 开源生态
2. 协作、人、软件
3. 评估模型