Is there any way, how to programatically (like allocating and filling some array) check, how much memory can Dalvik allocate before OutOfMemoryError
appears? Is it possible to do it with Java?
Every Java application allocates memory when it runs. This is what we have done using
java -Xms<initial heap size> -Xmx<maximum heap size>.
Also, in Throwable block, you can do the following way:
Maybe this will solve the problem.
Hope it helps.. - Swifty McSwifterton 2012-04-04 06:00