你应该使用的列表,列表= dao.findAll(); (用户用户:名单){(用户); } 打印出每个用户对象,如果你想看到的内容的System.out.println(user.getUserName();};