brdbl么80%的码农都做不了架构师?>>>
public class JsonParser { public static String getJsonContext context,String path) { String params = “”; AssetManager assetManager = context.getResources).getAssets); try { InputStream ins = assetManager.openpath); byte[] buffer = new byte[ins.available)]; ins.readbuffer); ins.close); params = new Stringbuffer); JSONObject object = new JSONObjectparams); params = object.toString); } catch IOException e) { e.printStackTrace); } catch JSONException e) { e.printStackTrace); } return params; }}
<p隐形的樱桃载于:https://my.oschina.net/wfy94/blog/3037165