list =(List) hibernateSysManagerService.findByTId(Integer.parseInt(userid));
if(list!=null){
tuser = (Tuser)list.get(0);
}
System.out.println("测试"+tuser);
便抛出异常!
处理结果:System.out.println("测试"+tuser.getUserId());
一切正常。
总结: 当我们在打印输出进行测试时,一定要记住,最好不要直接将对象输出,这样容易造成混乱,即出现啦,StackOverFlowError;
if(list!=null){
tuser = (Tuser)list.get(0);
}
System.out.println("测试"+tuser);
便抛出异常!
处理结果:System.out.println("测试"+tuser.getUserId());
一切正常。
总结: 当我们在打印输出进行测试时,一定要记住,最好不要直接将对象输出,这样容易造成混乱,即出现啦,StackOverFlowError;