一、打印对象内容
![](https://i-blog.csdnimg.cn/blog_migrate/8f900a89c6347c561fdf2122f13be562.gif)
![](https://i-blog.csdnimg.cn/blog_migrate/961ddebeb323a10fe0623af514929fc1.gif)
@Autowired private Gson gson; String prettyJsonString = gson.toJson(entity); LOGGER.info(prettyJsonString);
二、查看key-value的方法
![](https://i-blog.csdnimg.cn/blog_migrate/8f900a89c6347c561fdf2122f13be562.gif)
![](https://i-blog.csdnimg.cn/blog_migrate/961ddebeb323a10fe0623af514929fc1.gif)
public void getSystemKey(){ File sysFile = new File("d:/study","sysFile.properties"); Properties sysPro = System.getProperties(); try { sysPro.store(new FileOutputStream(sysFile), "Properties ClASS(描述)"); } catch (FileNotFoundException e1) { e1.printStackTrace(); } catch (IOException e) { e.printStackTrace(); } }