Where is the write file location?

Using following code to store temp file,Where is the file actual store location?

IOUtils.write(json, new FileOutputStream(new File(jsonFileName)), "utf-8");

Well, you specify the path yourself in jsonFileName. In doubt, just set a breakpoint and inspect its value.

3 Likes

got it.jsonFileName stands for fileName only,not including location path.

https://docs.oracle.com/javase/8/docs/api/java/io/File.html

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.