1 9 package javolution.realtime; 10 11 import javolution.lang.Reference; 12 13 40 public final class StackReferenceextends RealtimeObject implements 41 Reference{ 42 43 46 private static final Factory FACTORY = new Factory() { 47 protected Object create() { 48 return new StackReference(); 49 } 50 51 protected void cleanup(Object obj) { 52 ((StackReference) obj)._value = null; 53 } 54 }; 55 56 59 private Object_value; 60 61 65 private StackReference() { 66 } 67 68 74 public staticStackReference newInstance() { 75 return (StackReference) FACTORY.object(); 76 } 77 78 public Objectget() { 80 return _value; 81 } 82 83 public void set(Objectvalue) { 85 _value = value; 86 } 87 } | Popular Tags |