获取设备内存 Xcode

发布于 2024-09-29 19:44:27 字数 149 浏览 0 评论 0原文

我真的需要知道一种方法来获取当前设备的:

  1. 活动内存
  2. 非活动内存
  3. 有线内存
  4. 空闲
  5. 内存总内存

任何信息、代码或任何内容都有帮助。

提前致谢。

I really need to know of a way to get the current device’s:

  1. Active Memory
  2. Inactive Memory
  3. Wired Memory
  4. Free Memory
  5. Total Memory

Any information, code or anything is helpful.

Thanks in advance.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

往日情怀 2024-10-06 19:44:28

桌面使用 Mach 调用 host_statistics64() 来获取该信息。您可以在 vm_stat 的源代码中看到它的使用命令

The desktop uses the Mach call host_statistics64() to get that information. You can see it in use in the source code for the vm_stat command.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文