package Patterns.Flyweight;

/**
 * @author SlickNutter
 */
public class Oak implements TreeComon{
    private static Oak oak = null;
    private Oak() {
        oak = this;
    }
    private static boolean isInstanced() {
        return oak != null;
    }
    
    public String getModel() {
        return "Super sturdy Oak model!";
    }
    public static Oak Instance() {
        if (isInstanced()) {
            return oak;
        }
        else {
            return new Oak();
        }
    }
}

@@ -119,18 +119,16 @@
 Oak 
-oak = null
+instance
 ;%0A  
@@ -157,102 +157,18 @@
     
-oak = this;%0A    %7D%0A    private static boolean isInstanced() %7B%0A        return oak != null;
 %0A    %7D
+    
 %0A   
@@ -244,24 +244,29 @@
 el!%22;%0A    %7D%0A
+    %0A
     public s
@@ -304,21 +304,26 @@
 if (
+ 
 i
-sI
 nstance
-d()
+ == null 
 ) %7B%0A
@@ -338,18 +338,28 @@
     
-return oak
+instance = new Oak()
 ;%0A  
@@ -378,25 +378,17 @@
     
-else %7B%0A  
+%0A
         
   re
@@ -387,37 +387,24 @@
     
-  
 return 
-new Oak();%0A        %7D
+instance;
 %0A   

Update Oak.java