当前位置: 代码迷 >> J2SE >> 有人遇见过对象申请不下来的情况吗?等待中
  详细解决方案

有人遇见过对象申请不下来的情况吗?等待中

热度:36   发布时间:2016-04-24 14:01:04.0
有人碰见过对象申请不下来的情况吗?等待中
System.out.println( "eee   in   the   file   of   PackageApplicationManagementAgent_ApplicationManagementAgent ");
GUIAgent   =   new   PackageGUIAgent_GUIAgent(this);
System.out.println( "aab   in   the   file   of   PackageApplicationManagementAgent_ApplicationManagementAgent ");
中间申请对象程序就不走了,也不报错,什么问题

------解决方案--------------------
很有可能是你在
PackageGUIAgent_GUIAgent的构造函数里面对PackageGUIAgent_GUIAgent进行了new操作
这样就会循环申请空间,导致程序一直在吃内存,运行不下去
------解决方案--------------------
这样写会有问题么?---- GUIAgent = new PackageGUIAgent_GUIAgent(this);
  相关解决方案