【文件属性】:
文件名称:json2Gson:使用Python脚本将JSON输入转换为Java类以与GSON Java库一起使用
文件大小:3KB
文件格式:ZIP
更新时间:2021-05-15 07:20:58
Python
json2Gson
使用Python脚本将JSON输入转换为Java类以与GSON Java库一起使用
虽然将编译结果,并且外观将达到您的期望,但是此脚本有些无法为您完成的事情(例如,使用枚举而不是字符串..)。 一定要查看输出内容:)
用法
usage: json2Gson.py [-h] [--class_name NAME]
Convert a sample json feed into Java classes for use with Gson
optional arguments:
-h, --help show this help message and exit
--class_name NAME The name of the class for the top level Json object
例子
给定以下json:
{
【文件预览】:
json2Gson-master
----json2Gson.py(4KB)
----.gitignore(713B)
----README.md(2KB)
----sample.json(338B)