른록노트
[JAVA]inputstream을 JSONobject로 변경하는 방법 본문
Since you're already using Google's Json-Simple
library, you can parse the json from an InputStream
like this:
InputStream inputStream = ... //Read from a file, or a HttpRequest, or whatever.
JSONParser jsonParser = new JSONParser();
JSONObject jsonObject = (JSONObject)jsonParser.parse(
new InputStreamReader(inputStream, "UTF-8"));
참고사이트
https://stackoverflow.com/questions/22461663/convert-inputstream-to-jsonobject
반응형
Comments