黑莓应用程序 - 获取应用程序的内存使用情况统计 [英] Blackberry application - get application memory usage stats

查看:129
本文介绍了黑莓应用程序 - 获取应用程序的内存使用情况统计的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图让具体到我们的应用程序的内存使用情况统计(RAM,Flash和对象句柄),到(而不是通过探查)显示设备上。我一直在使用内存类跟踪普通内存的使用情况,但无法找到一种方式来获得特定的存储信息。

I'm trying to get the memory usage statistics (RAM, Flash and object handles) specific to our application, to be displayed on the device (not through the profiler). I've been using the Memory class to track general memory usage, but could not find a way to get the specific memory info.

有没有办法摆脱黑莓这一信息?也许使用应用程序的进程id?

Is there a way to get this information from the Blackberry? Maybe using the application's process id?

推荐答案

另外一个的运行也给人总的纪念品统计...

another one Runtime but also gives total mem stats...

您可以用模块做的是得到它的code尺寸<一个href=\"http://www.blackberry.com/developers/docs/4.0.2api/net/rim/device/api/system/$c$cModuleManager.html#getModule$c$cSize%28int%29\"相对=nofollow> $ C $#cModuleManager.html getModule codeSIZE(INT)

what you can do with module is get it's code size CodeModuleManager.html#getModuleCodeSize(int)

另一个技巧是在应用程序启动和主屏幕后的比较记忆统计数字将是presented

another tip is to compare memory statistic on app start and after main screen will be presented

也可以测量应用程序的 sizeof的用于Java - 对象大小重新

also you could measure size of each object in application Sizeof for Java - Object sizing revisited

但所有这些活动本身也会影响性能:)

but all this activity itself will change performance :)

这篇关于黑莓应用程序 - 获取应用程序的内存使用情况统计的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆