ITeye博客

如何得到Java应用程序的可用内存?

fish8077 · 2011-02-22 10:38 · java · 编程语言 · Markdown


public class MemoryExp {
    public static void main(String[] args) {
        System.out.println("Total Memory"+Runtime.getRuntime().totalMemory()); 
        System.out.println("Free Memory"+Runtime.getRuntime().freeMemory());
    }
}

评论(0)

暂无评论。

评论功能维护中,当前仅展示历史评论。