Json 读取

来源:互联网 发布:nginx set 全局变量 编辑:程序博客网 时间:2024/05/16 18:36

json 读取。。。

import org.json.JSONObject;String menu_config_json = "{\"serverIp\":\""+txt_serverip.getText()+"\",\"customerId\":\""+txt_customerid.getText() + "\",\"sldId\":\""+txt_sldid.getText()+"\",\"password\":\""+ txt_password.getText()+"\" }";String menuConfig = fu.readTextFile(fu.getSDCARD()+"menu_config.ini");try {           JSONObject jsonObj = new JSONObject(menuConfig);           String server_ip = jsonObj.getString("serverIp");          String cid = jsonObj.getString("customerId");          String tid = jsonObj.getString("sldId");


原创粉丝点击