1 2 17 18 package org.apache.poi.hwpf.model; 19 20 import org.apache.poi.hwpf.sprm.SprmBuffer; 21 22 import java.lang.ref.SoftReference ; 23 24 public class CachedPropertyNode 25 extends PropertyNode 26 { 27 protected SoftReference _propCache; 28 29 public CachedPropertyNode(int start, int end, SprmBuffer buf) 30 { 31 super(start, end, buf); 32 } 33 34 protected void fillCache(Object ref) 35 { 36 _propCache = new SoftReference (ref); 37 } 38 39 protected Object getCacheContents() 40 { 41 return _propCache == null ? null : _propCache.get(); 42 } 43 44 47 public SprmBuffer getSprmBuf() 48 { 49 return (SprmBuffer)_buf; 50 } 51 52 53 } 54 | Popular Tags |