Is it possible to Log.p("amount of Ram consumed"); by an app?
And Log.p("amount of Storage used"); by an app?
Yes but not reliably. Devices are pretty problematic with RAM allocations per app as they sequester memory in ways that are very unclear. Runtime.freeMemory should work with the current iOS VM and produce "something" but I'm not sure how valuable that will be.
Keep in mind that the GC in all platforms will cause issues as there is no guarantee System.gc() will do anything or how long it will take to do whatever it is that isn't guaranteed...
If you want to check memory leaks in your app I suggest using a memory profiler on the desktop. The NetBeans one works great and you can see memory growing without shrinking if you have a memory issue. You can track it down to a specific memory leak very easily.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With