diff options
author | Dominik Stadler <centic@apache.org> | 2016-12-11 20:58:03 +0000 |
---|---|---|
committer | Dominik Stadler <centic@apache.org> | 2016-12-11 20:58:03 +0000 |
commit | f843a1619246f6b70fb22afe91e3d5f742fff2c2 (patch) | |
tree | 2508e719041fc68472ebcad6e21d3b1a6e7ecc30 /src | |
parent | 2a1ac42781cb95b32242c6fdb521c99457b02ca8 (diff) | |
download | poi-f843a1619246f6b70fb22afe91e3d5f742fff2c2.tar.gz poi-f843a1619246f6b70fb22afe91e3d5f742fff2c2.zip |
Print out amount of available memory during startup of OOXMLLite
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1773633 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src')
-rw-r--r-- | src/ooxml/java/org/apache/poi/util/OOXMLLite.java | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/ooxml/java/org/apache/poi/util/OOXMLLite.java b/src/ooxml/java/org/apache/poi/util/OOXMLLite.java index d537a9d3a6..4e459c1f2d 100644 --- a/src/ooxml/java/org/apache/poi/util/OOXMLLite.java +++ b/src/ooxml/java/org/apache/poi/util/OOXMLLite.java @@ -76,6 +76,13 @@ public final class OOXMLLite { } public static void main(String[] args) throws IOException, ClassNotFoundException { + System.out.println("Free memory (bytes): " + + Runtime.getRuntime().freeMemory()); + long maxMemory = Runtime.getRuntime().maxMemory(); + System.out.println("Maximum memory (bytes): " + + (maxMemory == Long.MAX_VALUE ? "no limit" : maxMemory)); + System.out.println("Total memory (bytes): " + + Runtime.getRuntime().totalMemory()); String dest = null, test = null, ooxml = null; |