开发者

j2me Application shows out of memory exception in JBLEND

开发者 https://www.devze.com 2023-01-29 19:38 出处:网络
my j2me application shows out of memory exception in JBLEND. It work fine in JBED. By monitoring the memory, I realized that the document.parse(xmlParser) method consumes a lot of memory开发者_如何学G

my j2me application shows out of memory exception in JBLEND. It work fine in JBED. By monitoring the memory, I realized that the document.parse(xmlParser) method consumes a lot of memory开发者_如何学Go. I think the reason for the excption is memory is not freeing after parsing xml. is it right??? How can i solve the problem???


Whatever document.parse(xmlParser) returns, you should dereference it as soon a you don't need it anymore, i.e. you should set fields pointing to the returned object to null (or unset indirect references).

I've never used JBLEND or JBED, but the Wireless Toolkit respectively JaveME SDK also has a nice memory profiler which helps you track down memory and object reference problems.

0

精彩评论

暂无评论...
验证码 换一张
取 消