From 95581d9b760785ed14bbe428e75bc34fbda1b1df Mon Sep 17 00:00:00 2001 From: rayworks Date: Tue, 13 Mar 2018 10:17:51 +0800 Subject: [PATCH] update the code related to 'SoftReference' usage --- notes/JVM.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/notes/JVM.md b/notes/JVM.md index 285b59d3..9535c32a 100644 --- a/notes/JVM.md +++ b/notes/JVM.md @@ -171,7 +171,7 @@ Object obj = new Object(); ```java Object obj = new Object(); -WeakReference wf = new WeakReference(obj); +SoftReference sf = new SoftReference(obj); ``` #### 1.3.3 弱引用 @@ -689,3 +689,5 @@ protected synchronized Class loadClass(String name, boolean resolve) throws C ```java java -Xmx12m -Xms3m -Xmn1m -XX:PermSize=20m -XX:MaxPermSize=20m -XX:+UseSerialGC -jar java-application.jar ``` + +