Eclipse运行程序提示:Exception in thread "main" java.lang.OutOfMemoryError: Java heap space

时间:2014-06-21 21:41:22   收藏:0   阅读:336
问题描述:
Exception in thread "main" java.lang.OutOfMemoryError: Java heap space

问题原因:
程序中对象引用过多导致堆空间不足,导致内存溢出

解决方案:
(增大Java虚拟机的内存空间)
打开Eclipse,选择“Run” - “Run Configurations” - “(x)=Arguments”,VM arguments栏中填写 -Xmx800m
bubuko.com,布布扣

Eclipse运行程序提示:Exception in thread "main" java.lang.OutOfMemoryError: Java heap space,布布扣,bubuko.com

评论(0
© 2014 mamicode.com 版权所有 京ICP备13008772号-2  联系我们:gaon5@hotmail.com
迷上了代码!